Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Technical Support
 How to exclude some code depend on #define?

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
Teerayoot Posted - May 03 2007 : 04:19:19 AM
I'm working on some project that use Qt framework 4.2.3

and Qt header contain
a conditional defination (#ifdef QT3_SUPPORT) that is for support old code

VS2005 mark that code gray ,but VSX not

method that for old code still show in VAView ,ToolTIP,etc


How to prevent it from show old code,that has many method i need to see.


Thank in advance.
3   L A T E S T    R E P L I E S    (Newest First)
feline Posted - May 07 2007 : 3:08:44 PM
I would not have expected that to work, but I am very happy it does
Teerayoot Posted - May 05 2007 : 11:12:39 AM
ok,I got more easy solution

Your method need to edit every header files.
My method is

push this line of code to VA stdafx.h


#define QT3_SUPPORT #if 0


Now nomore old code show. :)
feline Posted - May 03 2007 : 3:04:25 PM
We are considering doing this in the future:

case=4059

For now, if you can modify the Qt header files slightly then you try the following method, which should work. The Qt header becomes:

#define VA_IGNORE_THIS_START
#define VA_IGNORE_THIS_END

class QWidget
{
    // code...

VA_IGNORE_THIS_START
#ifdef QT3_SUPPORT
    // old style code
#endif
VA_IGNORE_THIS_END

    // code...
};


Then edit VA's "StdAfx.h" file as explained in this FAQ entry:

http://docs.wholetomato.com?W302

and add the entries:

#define VA_IGNORE_THIS_START /*
#define VA_IGNORE_THIS_END */


at the bottom. This file is used to help VA's parser with difficult code, and can be used to work around odd effects. After modifying this file you need to rebuild the VA symbol database for the changes to take effect:

VA Options -> Performance -> General -> Rebuild symbol databases

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