VC express problem

If you are using the main C++ distribution of wxWidgets, Feel free to ask any question related to wxWidgets development here. This means questions regarding to C++ and wxWidgets, not compile problems.
Post Reply
mlli4
In need of some credit
In need of some credit
Posts: 2
Joined: Tue Dec 27, 2005 5:05 pm

VC express problem

Post by mlli4 »

When I use VC express to compile my codes. The application lose the look of XP theme. Anyone knows how to fix it?

I included the default .rc file but delete the manfest inside.
sethjackson
Super wx Problem Solver
Super wx Problem Solver
Posts: 396
Joined: Wed Oct 05, 2005 1:19 am

Re: VC express problem

Post by sethjackson »

mlli4 wrote:When I use VC express to compile my codes. The application lose the look of XP theme. Anyone knows how to fix it?

I included the default .rc file but delete the manfest inside.
You need the manifest thats what gives you the XP theme IIRC. :)
mlli4
In need of some credit
In need of some credit
Posts: 2
Joined: Tue Dec 27, 2005 5:05 pm

Re: VC express problem

Post by mlli4 »

sethjackson wrote:
mlli4 wrote:When I use VC express to compile my codes. The application lose the look of XP theme. Anyone knows how to fix it?

I included the default .rc file but delete the manfest inside.
You need the manifest thats what gives you the XP theme IIRC. :)
But the manifest in the default .rc file conflicts with the one generated by the linker in VC 8 express
sethjackson
Super wx Problem Solver
Super wx Problem Solver
Posts: 396
Joined: Wed Oct 05, 2005 1:19 am

Re: VC express problem

Post by sethjackson »

mlli4 wrote:
sethjackson wrote:
mlli4 wrote:When I use VC express to compile my codes. The application lose the look of XP theme. Anyone knows how to fix it?

I included the default .rc file but delete the manfest inside.
You need the manifest thats what gives you the XP theme IIRC. :)
But the manifest in the default .rc file conflicts with the one generated by the linker in VC 8 express
The linker generates a manifest??? :shock: Anyways post the .rc file please.
sethjackson
Super wx Problem Solver
Super wx Problem Solver
Posts: 396
Joined: Wed Oct 05, 2005 1:19 am

Post by sethjackson »

Here is a sample manifest file.

Code: Select all

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly
  xmlns="urn:schemas-microsoft-com:asm.v1"
  manifestVersion="1.0">
<assemblyIdentity
    name="TGA Loading.default.App"
    processorArchitecture="x86"
    version="1.0.0.0"
    type="win32"/>
<description>Executable</description>
<dependency>
    <dependentAssembly>
        <assemblyIdentity
            type="win32"
            name="Microsoft.Windows.Common-Controls"
            version="6.0.0.0"
            processorArchitecture="x86"
            publicKeyToken="6595b64144ccf1df"
            language="*"
        />
    </dependentAssembly>
</dependency>
</assembly>

Also I assume you have the XP theme on. :lol:

EDIT:

You can use this manifest but you might want to change the name tag.

Code: Select all

name="TGA Loading.default.App"
to something like

Code: Select all

name="your_app_name_here.default.App"
hajokirchhoff
Earned a small fee
Earned a small fee
Posts: 17
Joined: Fri Dec 23, 2005 4:43 pm
Contact:

Re: VC express problem

Post by hajokirchhoff »

mlli4 wrote:When I use VC express to compile my codes. The application lose the look of XP theme. Anyone knows how to fix it?

I included the default .rc file but delete the manfest inside.
Instead of deleting the manifest inside, define wxUSE_NO_MANIFEST=1 in the project settings for your .rc file.

See http://litwindow.blogspot.com

specifically

http://litwindow.blogspot.com/2005/12/u ... to_19.html

on how to set up and use the manifest with Visual Studio Express 8.

You probably made a mistake deleting the manifest or setting your linker settings.

Best regards

Hajo
--
wxVisualSetup - integrate wxWidgets into Visual Studio
http://www.litwindow.com/wxVisualSetup
Tips & Tricks for wxWidgets & MS Visual Studio
http://www.litwindow.com/Knowhow/knowhow.html?src=ml
lowjoel
Part Of The Furniture
Part Of The Furniture
Posts: 1511
Joined: Sun Jun 19, 2005 11:37 am
Location: Singapore
Contact:

Post by lowjoel »

manifests are the way XP/2003 knows which assemblies your apps depend on hence using those. One manifest is in include/wx/msw, and another is generated by the linker when linkimng to msvcr80 and msvcp80. mt.exe embeds those manifests into the exe. see VC/bin for mt.exe
madhan
Earned a small fee
Earned a small fee
Posts: 15
Joined: Mon May 30, 2005 4:05 am

In case someone has the same problem

Post by madhan »

I ran into the same issue. I was using VC Express 8.0.

I finally solved the problem and got the XP theme by doing the following.

1) Created my own app.rc file with the following contents.

#include "wx/msw/wx.rc"

(Make sure the include paths point to the right directories)

2) Add the .rc file to Resource Files section in the VC project

3) In the properties, specify wxUSE_NO_MANIFEST in the Resources->Preprocessor Definitions

4) In the Project Properties->Manifest Tool->Input & Output ->Additional Preprocessor, include c:\pgmming\wxWidgets-2.6.2\include\wx\msw\wx.manifest file.

Now build you app, and you should get the XP Theme look! Enjoy!
Post Reply