Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Feature Requests
 Virtual Space Size for Indent Code at Line Begin

You must be registered to post a reply.
Click here to register.

Screensize:
UserName:
Password:
Format: BoldItalicizeUnderlineStrikethrough Align leftCenterAlign right Insert horizontal ruleUpload and insert imageInsert hyperlinkInsert email addressInsert codeInsert quoted textInsert listInsert Emoji
   
Message:

Forum code is on.
Html is off.

 
Check to subscribe to this topic.
   

T O P I C    R E V I E W
drzoom Posted - Jul 07 2006 : 09:20:25 AM
I'm working with proportional fonts in the code editor (it's easier to read, ... try it, use Verdana as Font).

Because of the indent, I'm used to use only tabs for indent code. So I can choose the size of the indent with the size of a Tab:

foo()
{
(tab)if( foo )
(tab)(tab)DoSomething();
}

At my current workplace, the code guidelines suggest spaces for indent. And only 2 spaces. With a proportional font, the indent is really small.

So it would be a big improvement for me, if I could choose the size of a space at the start of a line. This is only necessary if the a line of code is starting with spaces.

.oO( It would be a Dream :-)
2   L A T E S T    R E P L I E S    (Newest First)
feline Posted - Jul 08 2006 : 2:31:45 PM
could you talk to the people who set the code guidelines? that sounds like a terribly small indent, in terms of readability.

another way forward is to look for a different font to use, one where a space character takes up more room. is it possible to manually edit the font files to achieve this end? i am aware of the idea of font editors, but never having used one i do not know their limits.

as for VA, the IDE does the basic drawing, while VA hooks in and does its clever bits behind the IDE's back. this shows up in the "cropping" of italic words with some fonts. VA cannot make the work take up more space, so there is not room for the last italic letter. so for technical reasons this is probably something VA could never do.
jpizzi Posted - Jul 07 2006 : 10:18:12 PM
I'm not sure how one might go about this. The difficulty would be the multiple levels of indentation. It sounds like what you are really after is, "Change the size of a space when it is not preceded by any non-space characters."

As an alternative (I know, not ideal, but...), you could use the IDE's tabify and untabify features to manipulate the code while you are editting it.

Or, do a global search and replace with tabs for two spaces (or whatever makes it easier for you to see).

If your concern is primarily code you create, then you could create all your code with the tabsize as 4 (or 5 or whatever) spaces, leave tabs in the code, then before you commit to version control (or whatever), change the tabsize to two and untabify the file.

© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000