From: David McGlone on 27 Apr 2010 16:33 Hi everyone. I got a quickie LOL is there a way to auto indent code. I'm using Kate and I have it set so the tab is only 4 spaces, but I was wondering if there was an easier way than to have to hit the tab key 1x then 2x then 3x then 2x then 1x to create nice laid out code like this: ----- ----- ----- ----- ----- ----- ----- ----- ----- or: function() { function here } -- Blessings, David M.
From: shiplu on 27 Apr 2010 16:43 There is a command "indent" in your kde. Check the manual Shiplu Mokaddim My talks, http://talk.cmyweb.net Follow me, http://twitter.com/shiplu SUST Programmers, http://groups.google.com/group/p2psust Innovation distinguishes bet ... ... (ask Steve Jobs the rest)
From: Ashley Sheridan on 27 Apr 2010 16:55 On Tue, 2010-04-27 at 16:33 -0400, David McGlone wrote: > Hi everyone. > > I got a quickie LOL > > is there a way to auto indent code. I'm using Kate and I have it set so the > tab is only 4 spaces, but I was wondering if there was an easier way than to > have to hit the tab key 1x then 2x then 3x then 2x then 1x to create nice laid > out code like this: > > ----- > ----- > ----- > ----- > ----- > ----- > ----- > ----- > ----- > > or: > > function() { > > function here > } > > -- > Blessings, > David M. > I use Kate too, and the indentation changed slightly in KDE 4. In the configure dialogue window, go down to the Editing section in the left menu and set the number of spaces to use in both the General tab (under Tabulators) and the Indentation tab (under Indentation Properties. If they are both different then you have to hit the tab key 4 times in order for your spaces to be replaced by a tab character. Thanks, Ash http://www.ashleysheridan.co.uk
From: "D. Dante Lorenso" on 27 Apr 2010 19:00 On 4/27/2010 3:55 PM, Ashley Sheridan wrote: > On Tue, 2010-04-27 at 16:33 -0400, David McGlone wrote: >> Hi everyone. >> I got a quickie LOL >> is there a way to auto indent code. I'm using Kate and I have it set so the >> tab is only 4 spaces, but I was wondering if there was an easier way than to >> have to hit the tab key 1x then 2x then 3x then 2x then 1x to create nice laid >> out code like this: I use PHPEclipse for this. It's not Eclipse with PDT, it's PHP Eclipse: http://www.phpeclipse.com/ The code formatter built into that formats my code when I hit Ctrl+Shift+F. No other code formatter works as well for what I've found. Many formatters just indent, this one will reformatt by putting brackets up or down, and reindent all the code to fit my coding standards. Project is getting a little old, though and doesn't yet support PHP 5.3 syntax, but it's still the best I've found. -- Dante ---------- D. Dante Lorenso dante(a)lorenso.com 972-333-4139
From: Programming Guides on 27 Apr 2010 21:52 On Tue, Apr 27, 2010 at 6:00 PM, D. Dante Lorenso <dante(a)lorenso.com> wrote: > On 4/27/2010 3:55 PM, Ashley Sheridan wrote: > >> On Tue, 2010-04-27 at 16:33 -0400, David McGlone wrote: >> >>> Hi everyone. >>> I got a quickie LOL >>> is there a way to auto indent code. I'm using Kate and I have it set so >>> the >>> tab is only 4 spaces, but I was wondering if there was an easier way than >>> to >>> have to hit the tab key 1x then 2x then 3x then 2x then 1x to create nice >>> laid >>> out code like this: >>> >> > I use PHPEclipse for this. It's not Eclipse with PDT, it's PHP Eclipse: > > http://www.phpeclipse.com/ > > The code formatter built into that formats my code when I hit Ctrl+Shift+F. > No other code formatter works as well for what I've found. Many formatters > just indent, this one will reformatt by putting brackets up or down, and > reindent all the code to fit my coding standards. > > Project is getting a little old, though and doesn't yet support PHP 5.3 > syntax, but it's still the best I've found. > > -- Dante > > ---------- > D. Dante Lorenso > dante(a)lorenso.com > 972-333-4139 > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > > vim ftw: 1. select the piece of code you want to indent (or select all with "ggVG") 2. Hit = 3. profit! -- http://programming-guides.com
|
Next
|
Last
Pages: 1 2 3 Prev: finding out datasets in a certain distance of a zip code Next: What is wrong with this code? |