Dark mode support - Bevel Button

I am sure others must have brought this up before but I want to share my experience.

I am finishing up an app for use at work… Even though almost no Macs there are running a Mac OS version that supports Dark Mode (I think one I am the only for is the only one), I decided to see how much work it would be to support it. Thsi si teh first time I ever switched into Dark Mode BTW.

Even though I am using 2019r1.1 so don’t have color groups to work with, with Xojo’s built in support all I needed were some minor tweeks… Luckily most of I was using for things like graphs and such worked about as well on a grayish background as they did on white.

The only issue was that I had used BevelButtons for picture buttons and those don’t support Dark Mode… If it was not for that it would not have taken me less than an hour to update the App for Dark mode…

The only Xojo supplied control that I could have used more or less out of the box without writing subclassing and writing more code instead was a single segment SegmentedControl (BTW although I don’t need a menu in this case, long ago I subclassed the SegmentedControl so segments could have menus)…

But SegmentedControl height can’t be increased and I needed something I had more control over size, which a BevelButton supplies…

Luckily I have the Einhugur Plugin and so used their BevelButton equivalent (PictureButton) instead, which does supportDark Mode…

But after this experience I really feel the Xojo Bevel Button should be updated to support Dark Mode…

Although BevelButtons may no longer be recommended for UI on a Mac, they fill a UI need that otherwise is not available out of the box, and should be. It would have taken me significantly longer to code my UI if i had had to write my own equivalent that supports Dark Mode

BTW while Dark Mode is easier on the eyes in general, I found the default IDE Xojo syntax coloring to be garish and distracting, so much so that when testing my App in Dark mode I found myself switching back to Light mode to edit the code!


1 Like

I don’t have a link handy but search the forum for Norman’s drop in replacement that supports dark mode.

1 Like

Thanks Kem,

I had forgotten about that… I may even have downloaded it…

I’ll find it, but as I have the Einhugur control and used that , I don’t need it.

That said, I really think Xojo really should update the Bevel button… New users would not be aware of either solution and as I said IMO it fills a needed UI niche that nothing else included does…

I expect eventually Xojo will need to support a “Dark Mode” on Windows as well, and when that happens, it might break Norms solution on that platform…

That is another reason IMO Xojo should update the bevel button (And keep it updated) even if it can’t be native on a Mac anymore ( is it now on Windows?)

  • Karen
1 Like

I was also going to suggest Norman’s Bevel replacement. +1 to that since it is free. I do have Einhugur and would use those if I needed to support that.

The reason the Xojo BevelButton doesn’t support Dark Mode is because Apple doesn’t support Dark Mode for BevelButtons and ask that you “avoid using them”

BevelButton is the fastest way to make your app look 20 years old.


IMO that depends on how one uses it.

I know that but disagree. IMO they can be used judicially, and not have to look out of place. They serve a purpose as I said that no other Xojo included control does, if for no other reason to make picture buttons easy in a RAD environment!

I would bet that the majority of apps created with Xojo are for in-house use, and for such apps strictly adhering to what Apple thinks is right matters less - particularly for Apps that need to be X-Platform. And as I said IMO Bevel buttons in MacOS really don’t look out of place.

I get that most of you selling apps to consumers won’t use them, but I suspect there are a good of number of people doing in-house apps that do, as they are very convenient.


1 Like

There is a style for a regular push button that makes it look like a bevel button and AFAIK that supports Dark Mode. However to get all of the features of the Xojo Bevel Button, it takes quite a bit of adapting and none of that is x-plat.

One would need to overlay it with a canvas in a container container control… Or at least that would have worked at one time… but now, can one still overlay a canvas over another control like that without an issue X-Platform?

IIRC that was an old trick in RB way back when (but without container controls as they did not exist and initially, and then were only in the higher level license !) to solve a lot of issues.


The regular Push Btn doesn’t support graphics to be displayed within.

As Apple does recommend to avoid Bevel Btns now I’ve replaced them with either Push Btns or a graphics object.

Writing an app for Apple devices and ‘nipping out for a coffee’ is the fastest way to make your app look old/ stop working.

1 Like

Yes, they said so, but they still do.
This is from Big Sur. See the last control on the left.
I don’t think it looks outdated.
(Technically it’s a Xojo Pushbutton with a declare into bevelStyle, and a few setImage… declares)