CodedK
asked on
XP Theme embeded in the app
Hi.
I'd like to know if its possible to embed a XP theme inside my app.
For example the user may use the classic blue theme in his PC but the app is like he runs Silver XP Theme.
Thanks in advance.
I'd like to know if its possible to embed a XP theme inside my app.
For example the user may use the classic blue theme in his PC but the app is like he runs Silver XP Theme.
Thanks in advance.
ASKER
Thanks..
Can u please help me little more...
This is the command:
SetWindowTheme: function(hwnd: HWND; pszSubAppName: LPCWSTR;pszSubIdList: LPCWSTR): HRESULT; stdcall;
How do i put Silver XP Theme?
Can u please help me little more...
This is the command:
SetWindowTheme: function(hwnd: HWND; pszSubAppName: LPCWSTR;pszSubIdList: LPCWSTR): HRESULT; stdcall;
How do i put Silver XP Theme?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
sorry about bad article link in previous comment ...
for viewing article download this rar :
www.mizan3.com/delphi/Support for Windows Visual Styles (Themes) API in your controls.rar
for viewing article download this rar :
www.mizan3.com/delphi/Support for Windows Visual Styles (Themes) API in your controls.rar
oh god ...
sorry again ...
true article link :
http://www.mizan3.com/delphi/delphitheme.rar
excuse me.
sorry again ...
true article link :
http://www.mizan3.com/delphi/delphitheme.rar
excuse me.
hi friend ...
very good idea finded!!!
1) in your program folder , open a new notepad(txt) file. paste this code to it :
<assembly xmlns="urn:schemas-microso ft-com:asm .v1" manifestVersion="1.0">
<assemblyIdentity
type="win32"
name="DelphiApplication"
version="1.0.0.0"
processorArchitecture="*"/ >
<dependency>
<dependentAssembly>
<assemblyIdentity
type="win32"
name="Microsoft.Windows.Co mmon-Contr ols"
version="6.0.0.0"
publicKeyToken="6595b64144 ccf1df"
language="*"
processorArchitecture="*"/ >
</dependentAssembly>
</dependency>
</assembly>
2) save the file with name : yourapp.exe.manifest
that "yourapp" is your application name.
3) run your application and enjoy with xp themes.
Regards.
very good idea finded!!!
1) in your program folder , open a new notepad(txt) file. paste this code to it :
<assembly xmlns="urn:schemas-microso
<assemblyIdentity
type="win32"
name="DelphiApplication"
version="1.0.0.0"
processorArchitecture="*"/
<dependency>
<dependentAssembly>
<assemblyIdentity
type="win32"
name="Microsoft.Windows.Co
version="6.0.0.0"
publicKeyToken="6595b64144
language="*"
processorArchitecture="*"/
</dependentAssembly>
</dependency>
</assembly>
2) save the file with name : yourapp.exe.manifest
that "yourapp" is your application name.
3) run your application and enjoy with xp themes.
Regards.
A Fact about "SetWindowTheme" Function :
SetWindowTheme is used to turn theming off for a particular window or to
restore the theme. It is not used to set a custom Theme.
To have your application use a custom theme you need to ownerdraw the window
and controls.
then i think , now you must use freewares (previous comments) or some code except this func.
Regards.
SetWindowTheme is used to turn theming off for a particular window or to
restore the theme. It is not used to set a custom Theme.
To have your application use a custom theme you need to ownerdraw the window
and controls.
then i think , now you must use freewares (previous comments) or some code except this func.
Regards.
ASKER
Hi.
mhamini what is that with the manifest ?
Did that but othing happened?
mhamini what is that with the manifest ?
Did that but othing happened?
Hi friend ...
{************************* ********** ********** ***}
FIRST :
Manifests , attach some visual settings to controls of your app.
in Delphi 7 , in win32 pallete , is a nice component to view the difference! (XPManifest)
I uploaded two programs for you to download and see the difference :
1) www.mizan3.com/delphi/With-XPManifest.rar
2) www.mizan3.com/delphi/Without-XPManifest.rar
so i guess this component be usefull to you.
{************************* ********** ********** ***}
SECOND :
I have an article that explain xp styles in delphi programming.
this article and source code , explain true way of Drawing controls! i think is usefull :
+) www.mizan3.com/delphi/Visual-Styles-in-Delphi.rar
{************************* ********** ********** ***}
THIRD :
I hope my activate be usefull for your perpose ... any comments is accepted(!!!) :)
Regards.
Mohammad Hosein Amini (mhamini)
mhamini@gmail.com
mohammadhoseinamini@yahoo. com
{*************************
FIRST :
Manifests , attach some visual settings to controls of your app.
in Delphi 7 , in win32 pallete , is a nice component to view the difference! (XPManifest)
I uploaded two programs for you to download and see the difference :
1) www.mizan3.com/delphi/With-XPManifest.rar
2) www.mizan3.com/delphi/Without-XPManifest.rar
so i guess this component be usefull to you.
{*************************
SECOND :
I have an article that explain xp styles in delphi programming.
this article and source code , explain true way of Drawing controls! i think is usefull :
+) www.mizan3.com/delphi/Visual-Styles-in-Delphi.rar
{*************************
THIRD :
I hope my activate be usefull for your perpose ... any comments is accepted(!!!) :)
Regards.
Mohammad Hosein Amini (mhamini)
mhamini@gmail.com
mohammadhoseinamini@yahoo.
ASKER
Hi mhamini.
I ve got Delphi 7. I know about XP Manifest.
I am asking if it is possible with code to have your form in every PC
have the XP Silver style, even if the PC runs on XP Blue style or some other style (Classic maybe).
I thought that this was the manifest you gave me.
Thanks for ur response.
I ve got Delphi 7. I know about XP Manifest.
I am asking if it is possible with code to have your form in every PC
have the XP Silver style, even if the PC runs on XP Blue style or some other style (Classic maybe).
I thought that this was the manifest you gave me.
Thanks for ur response.
ASKER
Thanks.
I found both components useful.
I prefer vcl though by Hypoviax.
I found both components useful.
I prefer vcl though by Hypoviax.
If you are not writing a commercial peice of software you could easily make do with the trial version of VCL Skins. I found prior to getting the full version, that you can remove the VCL Demo in the caption by making the caption:
NORMAL TEXT .
I.e. Your text with a single dot at the end. This spaces "VCL demo" off the screen so it cannot be seen,
Thanks,
Hypoviax
NORMAL TEXT .
I.e. Your text with a single dot at the end. This spaces "VCL demo" off the screen so it cannot be seen,
Thanks,
Hypoviax
Good Luck my Friend.
And now see this story :
I asked your question and mshkolnik replied ...
me :
(exactly your phrase)
if it is possible with code to have your form in every PC
have the XP Silver style, even if the PC runs on XP Blue style or some other style (Classic maybe).
{+++++++++++++++++++++++++ ++++++++++ +++}
mshkolnik :
Any application uses the default defined theme. So you can't.
Of course, application can draw anything without standard theming (as suggested third-party solutions for drawing) but this is not an answer for your question.
With best regards, Mike Shkolnik
http://www.scalabium.com
{+++++++++++++++++++++++++ ++++++++++ +++}
me again :
dear Mike! ... "You Can Not" can be a good answer!
thank you very much.
{+++++++++++++++++++++++++ ++++++++++ +++}
Link of Story :
+) http://www.delphipages.com/threads/thread.cfm?ID=130368&G=130368&SAR=TRUE
{+++++++++++++++++++++++++ ++++++++++ +++}
then, you seem to be true in choosing Components for your perpose.
Good Luck :)
I asked your question and mshkolnik replied ...
me :
(exactly your phrase)
if it is possible with code to have your form in every PC
have the XP Silver style, even if the PC runs on XP Blue style or some other style (Classic maybe).
{+++++++++++++++++++++++++
mshkolnik :
Any application uses the default defined theme. So you can't.
Of course, application can draw anything without standard theming (as suggested third-party solutions for drawing) but this is not an answer for your question.
With best regards, Mike Shkolnik
http://www.scalabium.com
{+++++++++++++++++++++++++
me again :
dear Mike! ... "You Can Not" can be a good answer!
thank you very much.
{+++++++++++++++++++++++++
Link of Story :
+) http://www.delphipages.com/threads/thread.cfm?ID=130368&G=130368&SAR=TRUE
{+++++++++++++++++++++++++
then, you seem to be true in choosing Components for your perpose.
Good Luck :)
uses
uxTheme;
SetWindowTheme()
see:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/shellcc/platform/commctls/userex/functions/setwindowtheme.asp
for more information