Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Feature Requests
 Padding/Deleting spaces after suggestions

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
azur Posted - Jan 13 2012 : 10:42:43 AM
Here is a example:

CString   strTool     = "VAssistX"
BYTE      nOurLicense = GetLicenseCount( strTool );

If our company grow a 'little bit' I have to adjust the variable. So I doubleklick BYTE, type "UL", and choose "ULONGLONG" - and lost my nice formating:

CString   strTool     = "VAssistX"
ULONGLONG      nOurLicense = GetLicenseCount( strTool );

I have to delete the surplus spaces.

The same happens if I use "int" instead of "ULONGLONG" - I had to add one space.




5   L A T E S T    R E P L I E S    (Newest First)
feline Posted - Jan 17 2012 : 3:15:06 PM
Unfortunately this just confirms that code formatting is quite a complex area, since no matter how many options you add, there are always likely to be requests for even more. Hopefully you can get somewhere using the IDE macro as a start point.
azur Posted - Jan 17 2012 : 02:43:18 AM
Yes, there are many options but especially I miss 2 options:

At first: a Parameter on a new line begins with a comma. That's a little bit unusual but have some advantage.

CString GetDisplayName                   // get the display name
      ( const CString & i_strSurename    // the surename
      , const CString & i_strFirstname   // the firstname
      , const CString & i_strTile        // the title
      );                                 // "[Title ] Surename [,Firstname]

At second: Declaration with assignment can only be aligned on name or assignment and not on both.

CString   strTool     = "VAssistX"
BYTE      nOurLicense = 42;

Thanks for the hint to "Great Code". It has also many options but it is a command line tool. The first thing to spring to mind is that you can't format only a marked part in a source file.
feline Posted - Jan 16 2012 : 10:11:24 AM
It is interesting that StyleManager did not have all the features you need, it seems to have quite a few options.

Another code formatting tool that I have come across is GC, Great Code, http://sourceforge.net/projects/gcgreatcode/
Which might be worth a look. From memory it takes a bit of setting up, but seems quite powerful.
azur Posted - Jan 16 2012 : 03:01:46 AM
I see the point.
I have tested the "StyleManager" but unfortunately he don't have the key features I need.
Thank you for the hint to "LineEmUp". This can be a start for my own macro.
feline Posted - Jan 13 2012 : 1:02:03 PM
Unfortunately we don't have any current plans to try and do this, since this gets us into code formatting, which is a very complex area, partly due to the vast number of different options you need to make everyone happy.

You might want to look into this commercial tool for code formatting:

http://www.profactor.co.uk/stylemanager.php

I have never used it myself, but it sounds promising from its website.

Alternatively, in the VS2010 sample IDE marco's, in the VSEditor section, there is a macro called "LineEmUp" which should help with reformatting your code after an edit.

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