How to change the default FireMonkey style in Delphi XE2
I saw a youtube video (can't remember which one) where the user changed an option in Delphi XE2 to change the 开发者_JAVA百科default style for an entire FireMonkey application. After much hunting I can't find the option.
IDE Insight for 'style' shows me 'Default Style - Custom Styles (Forms)' under 'Project Options'. But unless I'm being particularly thick, there's no such option there.
VCL Styles and Firemonkey Styles are fundamentally different.
Because of that I am not sure they should have used the same name.
VCL Styles
- Edited through: Tools|Style Designer (External App)
- Style Extension .VSF
- Format is Binary
- Can be set through: Project Options|Application| Appearance (Which just add
TStyleManager.SetStyle('StyleName');
to your code - Runtime control of styles can occur through the
TStyleManager
class
Firemonkey Styles
Editor is Internal to the IDE
- Accessed through
TStyleBook
Resource Property Editor Can also be accessed by Right click on any visual control and selecting either
- Edit Custom Style...
- Edit Default Style...
Note: These two menu choices are only available in desktop apps, not mobile apps.
Once in editor you can select the
Load..
button to change the style for the selected TStylebook. If the entire application is using the same TStyleBook it will change the whole application.
- Accessed through
- Style Extension .style
- Format is like a DFM
- Runtime control of styles can occur on each control and through the
TStyleBook
On windows 7 all of the styles both VCL and Firemonkey by default are placed in the
C:\Users\Public\Documents\RAD Studio\9.0\Styles
directory
One bullet point is a direct answer, but I felt like I had to give the long answer to help others.
精彩评论