FireMonkey property editor at runtime - delphi

In an HD form in FireMonkey, can I invoke the Brush property editor at runtime?
e.g. when the application is running, upon click of a button, I want to show the TBrush property editor in Modal. When the user selects the brush type, I want to apply it on the form or other components. Can this be achieved?

The brush property editor is TBrushDesigner in unit FMX.Design.Brush. It is a design time editor.
I doubt it is possible to show it at run-time as it has design-time dependencies. But if you have the FMX source code, you can try to work around that.

Related

Is it possible to have the Design/Form window open while the Code/Unit window is open? [duplicate]

I program in Delphi 2010, and I have enough screen space to show both a form and its code (that is, the code and design tabs of a form) at the same time, but so far I haven't had any luck trying to make that happen. Is there a way to customize the IDE to show both at the same time?
Set your desktop to "Classic Undocked"
Then you need to uncheck the embedded designer option in the VCL Designer options page:
You'll also have to restart the IDE for those changes to take effect.
The option Andreas is talking about is located under Tools | Options | Environment options | VCL Designer. It is called Embedded designer.
When you uncheck that a form will be displayed free-floating at its designed position instead of embedded in the docked editor. You need to restart the IDE for the option to take effect.
To show both form and code you will have to change your layout and/or move the form to a position where it doesn't cover the code editor.
As an alternative you could opt for the classic undocked layout. That way you can certainly position form and code editor not to overlap. To activate that you need View | Desktops | Classic Undocked.
Note: be aware that the position of the form at designtime is reflected at run-time if you have a form's Position property set to poDesigned.
Cool hack for Delphi XE4-XE7:
Changing 'HKEY_CURRENT_USER\Software\Embarcadero\BDS\11.0\Form Design\Embedded Designer' to FALSE will bring the classic designed back.

Is it possible to get a general OnClick on a form no matter where or what object I click?

I am working on a label printing project and I am using FastReports and also a TJvWizard from the JEDI Components Library.
I embedded the report's designer on a TpageControl and I added buttons and other components to the form so that I can interact from Delphi to the report's designer and add components to the report or modify their properties.
the problem I am having is that I need to know when the user selects (Clicks) a component in the report so that I show the correct properties for the component type that was selected. and I already asked on the fastreport support but there is no such event or any way the report notifies when it happens.
so, my question, is there any way to set a general on click event or something similar that lets my form know that the mouse was clicked, no matter where or what the user clicked but to be notified about the action itself of clicking.
I already tried setting the OnMouseDown event for the TTabSheet where the report's designer is embedded but It doesn’t trigger anything.
if it helps, I have my form and the TJvWizard in it, the wizard has some JvWizardIneriorPage and in one of those is my TPageControl which has two TTabSheet and I embedded the designer in one of those.
Edit:
in This other question provided by Sertac in the comments I found what I needed.

Default Firemonkey style sheet (file) for Delphi XE-6 Firemonkey Desktop Application?

Delphi XE-6 Firemonkey
I am trying to custom style the checkbox in a TGrid's TCheckColumn
I want to first understand how the default style is created. What all the elements are that make up its style.
Anyone know how to get the default style sheet for a default Firemonkey desktop application in Delphi XE-6?
If I drop a TGrid on a Firemonkey desktop application, and add a TCheckColumn to the grid, where is this default style of the grid, TCheckColumn / CheckCellStyle coming from?
I am trying to obtain its file (*.style), name. or the text.
If I add a TStyleBook, and then double click it and choose save, it only saves the StyleContainer, none of the styles for any control - especially the grid. Its just empty
object TStyleContainer
end
I have also tried to see if there was a default name in the StyleManager
for s in TStyleManager.StyleNames do
ShowMessage(S);
Anyone know how to get the default style sheet for a default firemonkey desktop application in Delphi XE-6?
Right click on the component (eg. Grid) and choose "Edit Style..." or "Edit Default Style" (can't remember which menu was in XE6). This will reveal the style elements of the component. Then you can save them to a .style file.

VCL style mac look style designer

Recently I've been doing some research in to VCL Styling (Embarcadero XE2 for Delphi).
I can load and set the styles so that works fine.
Currently I'm exploring the VCL Style Designer and what I try to figure out is how can I move the minimize, maximize, resize, close and help button to the left instead of the current default right while the application text (caption of the form) is on the right.
I am at my whits end and hope some one can give me some pointers.
So basically what I try to 'emulate' is the Mac look on a Windows form.
Any help is welcome.
What do you want accomplish is not related to the VCL Style Designer, instead you must create a custom form style hook.
Follow these steps.
Create (and register) a new form style hook descending from the TFormStyleHook class.
Override the PaintNC method to draw the title buttons in the new positions.
Handle the WM_NCMOUSEMOVE, WM_NCLBUTTONDOWN and WM_WM_NCLBUTTONUP messages to detect the status of the title buttons (hot, pressed) and fire the actions (close, restore, maximize, minimize).

put designer window in background

This is annoying ... In Delphi 7 when you clicked on the code window the form would automatically hide. Now it stays on top. I have to minimize it to remove it from focus. Are there any settings that correct this behaviour ? Also I must play hide and seek with component pallete on the right. I have it open but soon as I try and click on the scroll bar to try and search for my components I get everything replaced by Delphi projects etc. Then I must click inside the form for the component pallete to come back again. Annoying... Any way to disable this ?
For the first part of your question you can disable the embedded designer in order which the switch between the form and the code will be like the Delphi 7 IDE.
Tools-> Options -> Environment Options -> Vcl Designer -> Embedded designer (uncheck)
Also you can take a look to the Simon Stuart plugin RADSplit
Now for the component palette part, this windows change depending of the current active form , so if you active window is the form designer the Tool palette show the components else show the Delphi projects menu. Anyway Delphi XE2 includes the classic palette component which always show the components in top toolbar even if you are in the source code view.

Resources