Home All Groups Group Topic Archive Search About

Automatically fix indentation throughout my code

Author
13 Nov 2007 6:50 PM
Christian Blackburn
Hi Gang,

I have a program I wrote a long time ago and it must have had the
indent set to 2, which I've long since learned isn't clear enough.  Is
there a way to have it crawl through each module in my project and
properly indent the code?  By the way I have MZ-Tools installed and
suspect it might do that, though I don't know how/where.

Thanks,
Christian Blackburn

Author
13 Nov 2007 7:03 PM
dpb
Christian Blackburn wrote:
> Hi Gang,
>
> I have a program I wrote a long time ago and it must have had the
> indent set to 2, which I've long since learned isn't clear enough.  Is
> there a way to have it crawl through each module in my project and
> properly indent the code?  ...

Indent == 2 --> Code _IS_ properly indented... :)

Any other choice is an abomination to the indentation gods... :)

--
Author
13 Nov 2007 9:22 PM
Ralph
"dpb" <n***@non.net> wrote in message news:fhcskq$alm$2@aioe.org...
> Christian Blackburn wrote:
> > Hi Gang,
> >
> > I have a program I wrote a long time ago and it must have had the
> > indent set to 2, which I've long since learned isn't clear enough.  Is
> > there a way to have it crawl through each module in my project and
> > properly indent the code?  ...
>
> Indent == 2 --> Code _IS_ properly indented... :)
>
> Any other choice is an abomination to the indentation gods... :)
>

Pure heresy to suggest the ghods would condone such a thing. I seriously
advise you to avoid Thunderstorms.

Four is the correct distance.

As 2, 3, or even <shudder> 5 are too silly to even comment on - no further
explanation is necessary.

-ralph
Author
13 Nov 2007 9:30 PM
Bob Butler
"Ralph" <nt_consultin***@yahoo.com> wrote in message
news:%23YbygtjJIHA.4688@TK2MSFTNGP06.phx.gbl...
<cut>
> Four is the correct distance.

Four is just so wrong in so many ways
Author
14 Nov 2007 12:28 AM
Karl E. Peterson
Bob Butler wrote:
> "Ralph" <nt_consultin***@yahoo.com> wrote ...
> <cut>
>> Four is the correct distance.
>
> Four is just so wrong in so many ways

Not the least of which being, it's the MSFT default!
--
..NET: It's About Trust!
http://vfred.mvps.org
Author
14 Nov 2007 12:34 AM
Ralph
"Karl E. Peterson" <k***@mvps.org> wrote in message
news:OzCfRVlJIHA.5328@TK2MSFTNGP05.phx.gbl...
> Bob Butler wrote:
> > "Ralph" <nt_consultin***@yahoo.com> wrote ...
> > <cut>
> >> Four is the correct distance.
> >
> > Four is just so wrong in so many ways
>
> Not the least of which being, it's the MSFT default!
> --

Ahhh! Now that's vindication!

Nothing like the feeling of following in the footsteps of Giants.

-ralph
Author
14 Nov 2007 12:49 AM
Karl E. Peterson
Ralph wrote:
Show quote
> "Karl E. Peterson" <k***@mvps.org> wrote in message
> news:OzCfRVlJIHA.5328@TK2MSFTNGP05.phx.gbl...
>> Bob Butler wrote:
>>> "Ralph" <nt_consultin***@yahoo.com> wrote ...
>>> <cut>
>>>> Four is the correct distance.
>>>
>>> Four is just so wrong in so many ways
>>
>> Not the least of which being, it's the MSFT default!
>
> Ahhh! Now that's vindication!
>
> Nothing like the feeling of following in the footsteps of Giants.

There ya go!

So, you still have your file extensions turned off too, then, eh?
--
..NET: It's About Trust!
http://vfred.mvps.org
Author
14 Nov 2007 1:36 AM
Ralph
Show quote
"Karl E. Peterson" <k***@mvps.org> wrote in message
news:OyH$xglJIHA.4948@TK2MSFTNGP02.phx.gbl...
> Ralph wrote:
> > "Karl E. Peterson" <k***@mvps.org> wrote in message
> > news:OzCfRVlJIHA.5328@TK2MSFTNGP05.phx.gbl...
> >> Bob Butler wrote:
> >>> "Ralph" <nt_consultin***@yahoo.com> wrote ...
> >>> <cut>
> >>>> Four is the correct distance.
> >>>
> >>> Four is just so wrong in so many ways
> >>
> >> Not the least of which being, it's the MSFT default!
> >
> > Ahhh! Now that's vindication!
> >
> > Nothing like the feeling of following in the footsteps of Giants.
>
> There ya go!
>
> So, you still have your file extensions turned off too, then, eh?
> --

File Extensions????
Author
14 Nov 2007 7:24 AM
Rick Rothstein (MVP - VB)
>> So, you still have your file extensions turned off too, then, eh?
>
> File Extensions????

Microsoft's default for WinXP and Vista is to...

   "Hide extensions for known file types"

in Window's Explorer meaning they think it wise for you to look at a
directory listing of say...

     MyPicture
     MyPicture
     MyPicture

when in fact they really are

     MyPicture.jpg
     MyPicture.bmp
     MyPicture.gif

You have to go out of your way using...

     Tools/Options/Folder Options/View/Advanced Settings

to turn them on. That is Microsoft's default for those operating systems
and, for the life of me, I can't fathom why this made sense to them.

Rick
Author
14 Nov 2007 8:46 PM
Karl E. Peterson
Rick Rothstein (MVP - VB) wrote:
>>> So, you still have your file extensions turned off too, then, eh?
>>
>> File Extensions????
>
> Microsoft's default for WinXP and Vista is to...
>
>   "Hide extensions for known file types"

I figured, of course, that he was just being a smartaxx and knew perfectly well what
I meant.  He's good at that.  :-)
--
432 Days, 20 Hours, 13 Minutes, and 15 Seconds
Author
14 Nov 2007 8:53 PM
Rick Rothstein (MVP - VB)
> 432 Days, 20 Hours, 13 Minutes, and 15 Seconds

This is new... what are you counting down (or up)?

Rick
Author
14 Nov 2007 9:04 PM
Karl E. Peterson
Rick Rothstein (MVP - VB) wrote:
>> 432 Days, 20 Hours, 13 Minutes, and 15 Seconds
>
> This is new... what are you counting down (or up)?

?now + 432 + 20/24  <bg>
--
432 Days, 19 Hours, 55 Minutes, and 52 Seconds
Author
14 Nov 2007 9:14 PM
Rick Rothstein (MVP - VB)
>>> 432 Days, 20 Hours, 13 Minutes, and 15 Seconds
>>
>> This is new... what are you counting down (or up)?
>
> ?now + 432 + 20/24  <bg>
> --
> 432 Days, 19 Hours, 55 Minutes, and 52 Seconds

Ah yes... **that** date.  Can't wait (and its still too far off)!

Rick
Author
14 Nov 2007 9:21 PM
dpb
Rick Rothstein (MVP - VB) wrote:
>>>> 432 Days, 20 Hours, 13 Minutes, and 15 Seconds
>>>
>>> This is new... what are you counting down (or up)?
>>
>> ?now + 432 + 20/24  <bg>
>> --
>> 432 Days, 19 Hours, 55 Minutes, and 52 Seconds
>
> Ah yes... **that** date.  Can't wait (and its still too far off)!

I could wait more easily if I had a better feel for the result... :(

--
Author
14 Nov 2007 9:33 PM
Rick Rothstein (MVP - VB)
>>>>> 432 Days, 20 Hours, 13 Minutes, and 15 Seconds
>>>>
>>>> This is new... what are you counting down (or up)?
>>>
>>> ?now + 432 + 20/24  <bg>
>>> --
>>> 432 Days, 19 Hours, 55 Minutes, and 52 Seconds
>>
>> Ah yes... **that** date.  Can't wait (and its still too far off)!
>
> I could wait more easily if I had a better feel for the result... :(

My feeling is it can't get worse... and the odds are strong that it won't
remain the same.

Rick
Author
14 Nov 2007 10:15 PM
dpb
Rick Rothstein (MVP - VB) wrote:
Show quote
>>>>>> 432 Days, 20 Hours, 13 Minutes, and 15 Seconds
>>>>>
>>>>> This is new... what are you counting down (or up)?
>>>>
>>>> ?now + 432 + 20/24  <bg>
>>>> --
>>>> 432 Days, 19 Hours, 55 Minutes, and 52 Seconds
>>>
>>> Ah yes... **that** date.  Can't wait (and its still too far off)!
>>
>> I could wait more easily if I had a better feel for the result... :(
>
> My feeling is it can't get worse... and the odds are strong that it
> won't remain the same.

_My_ feeling is it could be _much_ worse (and likely will be)...

--
Author
14 Nov 2007 10:40 PM
Karl E. Peterson
dpb wrote:
Show quote
> Rick Rothstein (MVP - VB) wrote:
>>>>>>> 432 Days, 20 Hours, 13 Minutes, and 15 Seconds
>>>>>>
>>>>>> This is new... what are you counting down (or up)?
>>>>>
>>>>> ?now + 432 + 20/24  <bg>
>>>>> --
>>>>> 432 Days, 19 Hours, 55 Minutes, and 52 Seconds
>>>>
>>>> Ah yes... **that** date.  Can't wait (and its still too far off)!
>>>
>>> I could wait more easily if I had a better feel for the result... :(
>>
>> My feeling is it can't get worse... and the odds are strong that it
>> won't remain the same.
>
> _My_ feeling is it could be _much_ worse (and likely will be)...

Awwwww, whaddaya got against Hillary? <gd&r>
--
432 Days, 18 Hours, 19 Minutes, and 26 Seconds
Author
14 Nov 2007 11:10 PM
dpb
Karl E. Peterson wrote:
Show quote
> dpb wrote:
>> Rick Rothstein (MVP - VB) wrote:
>>>>>>>> 432 Days, 20 Hours, 13 Minutes, and 15 Seconds
>>>>>>> This is new... what are you counting down (or up)?
>>>>>> ?now + 432 + 20/24  <bg>
>>>>>> --
>>>>>> 432 Days, 19 Hours, 55 Minutes, and 52 Seconds
>>>>> Ah yes... **that** date.  Can't wait (and its still too far off)!
>>>> I could wait more easily if I had a better feel for the result... :(
>>> My feeling is it can't get worse... and the odds are strong that it
>>> won't remain the same.
>> _My_ feeling is it could be _much_ worse (and likely will be)...
>
> Awwwww, whaddaya got against Hillary? <gd&r>

Let me count the ways... :)

Unfortunately, I see no alternatives (in the race, anyway) on either
side that are much to write home about...  :(

--
Author
14 Nov 2007 11:24 PM
Karl E. Peterson
dpb wrote:
Show quote
> Karl E. Peterson wrote:
>> dpb wrote:
>>> Rick Rothstein (MVP - VB) wrote:
>>>>>>>>> 432 Days, 20 Hours, 13 Minutes, and 15 Seconds
>>>>>>>> This is new... what are you counting down (or up)?
>>>>>>> ?now + 432 + 20/24  <bg>
>>>>>>> --
>>>>>>> 432 Days, 19 Hours, 55 Minutes, and 52 Seconds
>>>>>> Ah yes... **that** date.  Can't wait (and its still too far off)!
>>>>> I could wait more easily if I had a better feel for the result... :(
>>>> My feeling is it can't get worse... and the odds are strong that it
>>>> won't remain the same.
>>> _My_ feeling is it could be _much_ worse (and likely will be)...
>>
>> Awwwww, whaddaya got against Hillary? <gd&r>
>
> Let me count the ways... :)
>
> Unfortunately, I see no alternatives (in the race, anyway) on either
> side that are much to write home about...  :(

Yep, Neil got it right when he wrote...

   Lookin' for a Leader
   To bring our country home
   Re-unite the red white and blue
   Before it turns to stone

   Lookin' for somebody
   Young enough to take it on
   Clean up the corruption
   And make the country strong

   Walkin' among our people
   There's someone who's straight and strong
   To lead us from desolation
   And a broken world gone wrong

   Someone walks among us
   And I hope he hears the call
   And maybe it's a woman
   Or a black man after all

   Yeah maybe it's Obama
   But he thinks that he's too young
   Maybe it's Colin Powell
   To right what he's done wrong

   America has a leader
   But he's not in the house
   He's waling here among us
   And we've got to seek him out

   Yeah we've got our election
   But corruption has a chance
   We got to have a clean win
   To regain confidence

   America is beautiful
   But she has an ugly side
   We're lookin' for a leader
   In this country far and wide

   We're lookin' for a leader
   With the great spirit on his side

   Someone walks among us
   And I hope he hears the call
   And maybe it's a woman
   Or a black man after all

Unfortunately, as I see it, we're still looking...
--
432 Days, 17 Hours, 36 Minutes, and 11 Seconds
Author
15 Nov 2007 3:50 AM
Schmidt
"Karl E. Peterson" <k***@mvps.org> schrieb im Newsbeitrag
news:uKBf6VxJIHA.3400@TK2MSFTNGP03.phx.gbl...

> Unfortunately, as I see it, we're still looking...

Since youtube seems to become a serious
"election-platform" - what about him?

He can: Talk for himself.
http://www.youtube.com/watch?v=4anA3Lv_rec

He tells: The truth.
http://www.youtube.com/watch?v=kJ4SSvVbhLw

He loves: People.
http://www.youtube.com/watch?v=CTSo1jD_y4I

He knows: The demand for equality.
http://www.youtube.com/watch?v=cgps85scy1g

He sees: The essence behind things.
http://www.youtube.com/watch?v=AampoHyBWo8

And finally he has: Great visions about the future.
http://www.youtube.com/watch?v=2n2MS2biIk0

All in all - looks like a perfect candidate to me
(if I may say that from my "outside view"). ;-)

SCNR

Olaf
Author
15 Nov 2007 7:00 PM
Karl E. Peterson
Schmidt wrote:
Show quote
> "Karl E. Peterson" <k***@mvps.org> schrieb im Newsbeitrag
> news:uKBf6VxJIHA.3400@TK2MSFTNGP03.phx.gbl...
>
>> Unfortunately, as I see it, we're still looking...
>
> Since youtube seems to become a serious
> "election-platform" - what about him?
>
> He can: Talk for himself.
> http://www.youtube.com/watch?v=4anA3Lv_rec
>
> He tells: The truth.
> http://www.youtube.com/watch?v=kJ4SSvVbhLw
>
> He loves: People.
> http://www.youtube.com/watch?v=CTSo1jD_y4I
>
> He knows: The demand for equality.
> http://www.youtube.com/watch?v=cgps85scy1g
>
> He sees: The essence behind things.
> http://www.youtube.com/watch?v=AampoHyBWo8
>
> And finally he has: Great visions about the future.
> http://www.youtube.com/watch?v=2n2MS2biIk0
>
> All in all - looks like a perfect candidate to me
> (if I may say that from my "outside view"). ;-)

Oh man, I gotta look at those off the clock...  <bg>
--
431 Days, 21 Hours, 59 Minutes, and 24 Seconds
Author
16 Nov 2007 2:14 AM
Karl E. Peterson
Karl E. Peterson wrote:
Show quote
> Schmidt wrote:
>> "Karl E. Peterson" <k***@mvps.org> schrieb im Newsbeitrag
>> news:uKBf6VxJIHA.3400@TK2MSFTNGP03.phx.gbl...
>>
>>> Unfortunately, as I see it, we're still looking...
>>
>> Since youtube seems to become a serious
>> "election-platform" - what about him?
>>
>> He can: Talk for himself.
>> http://www.youtube.com/watch?v=4anA3Lv_rec
>>
>> He tells: The truth.
>> http://www.youtube.com/watch?v=kJ4SSvVbhLw
>>
>> He loves: People.
>> http://www.youtube.com/watch?v=CTSo1jD_y4I
>>
>> He knows: The demand for equality.
>> http://www.youtube.com/watch?v=cgps85scy1g
>>
>> He sees: The essence behind things.
>> http://www.youtube.com/watch?v=AampoHyBWo8
>>
>> And finally he has: Great visions about the future.
>> http://www.youtube.com/watch?v=2n2MS2biIk0
>>
>> All in all - looks like a perfect candidate to me
>> (if I may say that from my "outside view"). ;-)
>
> Oh man, I gotta look at those off the clock...  <bg>

Superb!  :-D
--
431 Days, 14 Hours, 45 Minutes, and 24 Seconds
Author
16 Nov 2007 4:09 AM
Stefan Berglund
On Thu, 15 Nov 2007 18:14:38 -0800, "Karl E. Peterson" <k***@mvps.org>
wrote:
in <#Y8OyZ$JIHA.1***@TK2MSFTNGP03.phx.gbl>

Show quote
>Karl E. Peterson wrote:
>> Schmidt wrote:
>>> "Karl E. Peterson" <k***@mvps.org> schrieb im Newsbeitrag
>>> news:uKBf6VxJIHA.3400@TK2MSFTNGP03.phx.gbl...
>>>
>>>> Unfortunately, as I see it, we're still looking...
>>>
>>> Since youtube seems to become a serious
>>> "election-platform" - what about him?
>>>
>>> He can: Talk for himself.
>>> http://www.youtube.com/watch?v=4anA3Lv_rec
>>>
>>> He tells: The truth.
>>> http://www.youtube.com/watch?v=kJ4SSvVbhLw
>>>
>>> He loves: People.
>>> http://www.youtube.com/watch?v=CTSo1jD_y4I
>>>
>>> He knows: The demand for equality.
>>> http://www.youtube.com/watch?v=cgps85scy1g
>>>
>>> He sees: The essence behind things.
>>> http://www.youtube.com/watch?v=AampoHyBWo8
>>>
>>> And finally he has: Great visions about the future.
>>> http://www.youtube.com/watch?v=2n2MS2biIk0
>>>
>>> All in all - looks like a perfect candidate to me
>>> (if I may say that from my "outside view"). ;-)
>>
>> Oh man, I gotta look at those off the clock...  <bg>
>
>Superb!  :-D

Yup, I just showed them all to my 14 and 15 year old sons who are
~critical thinkers~ educationally immersed in theater and improv and
neither could stop laughing.

---
Stefan Berglund
Author
27 Nov 2007 12:17 AM
Alfie [UK]
On Tue, 13 Nov 2007 10:50:19 -0800, Christian Blackburn
<christian.Blackb***@Yahoo.com> wrote:

>Hi Gang,
>
>I have a program I wrote a long time ago and it must have had the
>indent set to 2, which I've long since learned isn't clear enough.  Is
>there a way to have it crawl through each module in my project and
>properly indent the code?  By the way I have MZ-Tools installed and
>suspect it might do that, though I don't know how/where.
>
I can't believe I read through the whole 'holy war' thread (3 is the
deitie's own sweet number, sammit!) and didn't see anyone mention an
actual solution :)

I use SmartIndenter http://www.oaltd.co.uk/Indenter/Default.htm, simple,
customisable and it's free!
--
Alfie [UK]
<http://www.delphia.co.uk/>
If you give up drugs, alcohol and sex you don't actually live longer....it just seems longer.
Author
27 Nov 2007 1:00 AM
Robert Morley
How many spaces did you indent it? <lmao>


Rob

Show quote
"Alfie [UK]" <alfie@mail.invalid> wrote in message news:79omk31armvgmr8afj76ur46p9u1onmov4@4ax.com...
> I can't believe I read through the whole 'holy war' thread (3 is the
> deitie's own sweet number, sammit!) and didn't see anyone mention an
> actual solution :)
>
> I use SmartIndenter http://www.oaltd.co.uk/Indenter/Default.htm, simple,
> customisable and it's free!
> --
> Alfie [UK]
> <http://www.delphia.co.uk/>
> If you give up drugs, alcohol and sex you don't actually live longer....it just seems longer.
Author
27 Nov 2007 7:09 PM
Alfie [UK]
On Mon, 26 Nov 2007 20:00:48 -0500, "Robert Morley"
<rmor***@magma.ca.N0.Freak1n.sparn> wrote:

>How many spaces did you indent it? <lmao>

For newsreaders I use the standard '> ' so as to allow readers that have
hard-wired colour-coded indents to see and quote it correctly. As I have
to use such a reader at work for similar reasons I mildly dislike people
that turn off quote prefixes or use a different character or spacing
level.

For programming, I am (mostly) in control of my IDE and only 3 will do
as I'm the only person reading it :)
--
Alfie [UK]
<http://www.delphia.co.uk/>
If you put garbage in a computer you get garbage. But this garbage, having passed through a machine, is somehow ennobled and none dare criticize it.
Author
27 Nov 2007 8:52 PM
Bob Butler
"Alfie [UK]" <alfie@mail.invalid> wrote in message
news:vfqok31dnqq3lsci739l10llb47chsjtn2@4ax.com...
> For programming, I am (mostly) in control of my IDE and only 3 will do
> as I'm the only person reading it :)

Hmmm.  I think you misspelled "2"...
Author
27 Nov 2007 10:53 PM
Alfie [UK]
On Tue, 27 Nov 2007 12:52:53 -0800, "Bob Butler" <noway@nospam.ever>
wrote:

>"Alfie [UK]" <alfie@mail.invalid> wrote in message
>news:vfqok31dnqq3lsci739l10llb47chsjtn2@4ax.com...
>> For programming, I am (mostly) in control of my IDE and only 3 will do
>> as I'm the only person reading it :)
>
>Hmmm.  I think you misspelled "2"...

Nope, still can't see it. Are you trying to type '3' ?

I never understood why this was such a religious issue, with SmartIndent
or similar it is trivial to reformat an entire project to your own style
:)
--
Alfie [UK]
<http://www.delphia.co.uk/>
Bigamy is having one wife too many. Monogamy could be considered in the same way.

AddThis Social Bookmark Button