Jump to content
MJBComp

GExperts Toolbar Dark Mode

Recommended Posts

Can you tell me what the name of the GX_<filename>.pas that contains the toolbar icons?  I'm trying to modify the code to give me a Dark Mode look in Sidney 10.4?

Share this post


Link to post
16 hours ago, MJBComp said:

Can you tell me what the name of the GX_<filename>.pas that contains the toolbar icons?  I'm trying to modify the code to give me a Dark Mode look in Sidney 10.4?

I just had to look it up myself, so here is what I found:

 

The code for registering the GExperts actions with the IDE is TGXActionBroker.RegisterActionWithIde in GX_ActionBroker. This method is called from .RegisterAction and .RegisterMenuAction which in turn are called from various places within GExperts. The bitmap to use as an icon is passed as a parameter to that method. so if you grep for RegisterAction and RegisterMenuAction you should be able to find where these bitmaps come from.

 

Most of those bitmaps probably come from a call to GxLoadBitmapFromResource in GX_Utils, which loads these bitmpas from the resource file GXIcons.res (located in the images folder of the GExperts sources which is linked into the DLL. That resource file in turn is generated from  the bmp files in the same directory. So I guess it would be possible to somehow manipulate these bitmaps when they are being loaded or load different bitmaps for dark mode. Not sure whether that covers all bitmaps though.

Share this post


Link to post
Posted (edited)

I appreciate your response.  All i want to do is make the background panel Dark.  I do not want to manipulate the icons.  I'm not sure if those are SpeedButtons and if they are on a TPanel.  I"m trying to find in the code where to set the Canvas.Brush color or perhaps change the Transparency value from False to True.

 

The more i dig into this i think the default TColor might be set in the GxOtaGetIdeBaseRegistryKey Registry key.   I'm still digging.

Edited by MJBComp

Share this post


Link to post

The code for the toolbar itself is in the aptly named unit GX_Toolbar, which can be found in the subdirectory EditorToolbar of the source directory.

Since that is so obvious, I thought you were asking for more details, in particular since your question mentioned the icons.

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×