Closed mknepper closed 5 years ago
Would also like to add that changing the icon size from "small" to "automatic" renders this:
I also changed the icon style to Automatic (Tango) to see if it'd make a difference.
So, are the arrows always like this or just like this with the theme applied?
Only on this theme. I've tried others like Greybird, Numix, Adwaita and Arc and I don't seem to get the issue.
This has bugged me too. I couldn't ever figure out how to fix it. This will have to do with the libreoffice-gtk3 package which brings "GTK3" theme support to Libreoffice. It never worked right for whatever reason with Chicago95. It's not true GTK3 support, but just makes a mock version of the user theme installed then translates it to the VCL toolkit so that your widgets look similar. (A similar practice seen with QT5 and it's support for GTK themes.)
There are other parts in libreoffice-gtk3 that will look off too. Traditionally I just recommend removing that package and installing libreoffice-gtk
so that it falls back to the GTK2 version which appears to translate much better; however depending on your version of LO, there was a cell text rendering issue in the spreadsheet application while using the GTK2 plugin, which I'm unsure was ever addressed.
Since I can't inspect LO with a widget inspector tool like for native GTK3 applications, I haven't been able to determine the cause for this. The next best thing I could do is tediously reverse engineer a known working GTK3 theme with LO and slowly figure out what's missing. I suspect that the GTK3 to VCL plugin for LO is inspecting the user theme and is possibly expecting long since deprecated properties to use for its widgets, which shouldn't be in use. As the result, you get a half baked GTK3 theme for LO.
Interesting! Nice analysis, that's really cool. I'll try contacting the Libreoffice team to see if they can do anything about, otherwise I'm not sure there's much you can do.
I'll try to take a look at it soon if I can find the time. I can tell it's going to be one of those long research and trial and error scenarios since I failed to figure it out the last time, which is why I've kept it low priority since the gtk2 version works just fine.
Makes sense. I didn't know if it was pointed out yet or not. Thanks for being such an awesome dev. If I find anything I will let you know.
Just some notes from my experiences with theming and LibreOffice so far that may help, this may be a bit long sorry in advance:
--LibreOffice seems to ignore the arrow background image unless -gtk-icon-source is used to set the arrow image and will use it's default arrows instead if this property is not set. --OR--
--You can set the color: property for the "combobox button arrow" to transparent and the huge arrows will not be displayed in LibreOffice. This will not affect the arrows in your theme however LibreOffice comboboxes will now have no arrows.
--One hack I've used to compromise is I set: combobox button arrow { background-image: none;
combobox button { background-image: url("assets/arrow-down.png");
This will make LibreOffice use the specified arrow image. You will need to adjust the background image properties of coarse to make the arrow display correctly in your theme.
--LibreOffice also annoyingly seems to ignore the padding property entirely. This of coarse has been extremely frustrating trying to tweak my themes to work with LibreOffice.
--LibreOffice uses the "scrolledwindow" settings for the menubar this is why some themes appear to have an inset border around the menubar. One workaround I'm currently using is calling the scrolledwindow through parent widgets. eg paned > scrolledwindow, blahblahblah > scrolledwindow (insert long list of combinations here etc..) instead of using scrolledwindow directly.
-For example here's a quick modification I made for Chicago95 on my machine to get a decent compromise. It's not perfect however the arrows in LibreOffice appear slightly offset to the left since LibreOffice seems to modify the min-width property but it didn't seem to affect anything else in the main theme at all:
combobox button { background-position: calc(100%-6px); background-repeat: no-repeat; background-image: url("assets/arrow-down.png"); padding: 0px; margin: 0px; min-width: 0px; min-height: 0px; }
combobox { min-width: 20px; min-height: 20px; }
combobox button arrow { color: transparent; background-image: none; padding: 0px; min-width: 20px; min-height: 20px; border: 1px solid transparent; }
I hope this can help somewhat. As a side note the hack I'm currently using in most of my themes is using a border image to draw the combobox buttons. (I fit the combobox button image inside of the right border). This makes the button appear consistent in most applications including LibreOffice. It just seems like I'm resorting to using hacks like this in my themes just to facilitate LibreOffice instead of doing things the correct way but I understand it's an application most people use so I try my best to work around it.
I looked at the combobox button. It doesn't appear to have an active / checked state.
I'm not sure if it's technically correct or not but it seems to work for standard GTK3 applications. The only limitation I've noticed seems to be for LibreOffice as it appears to ignore this reference and doesn't display the changed state of the button when pressed. For example here's what I use on my Redmond97 theme for the active combobox, it's a bit of a hack that I use to get consistency between most GTK3 applications and LibreOffice by using the image border to display the actual button image:
combobox :checked { padding: 1px; border-color: @borders; border: 1px solid @dark_shadow; border-bottom: 1px solid @light_shadow; border-right: 1px solid @light_shadow; border-radius: 0px; box-shadow: 1px 1px @borders inset, -1px -1px @theme_bg_color inset; }
combobox button:checked, combobox button:active { margin: 2px; box-shadow: none; outline-color: transparent; background-color: transparent; border: solid; padding: 0px; border-width: 2px 18px 2px 2px; border-image: url("assets/combobox_checked.png"); border-image-slice: 2 18 2 2; }
It may be a non-issue here in a bit, since Xfce 4.14 just came out. Not sure how much work we'll go through involving that. Also, nice solution.
4.14 made it's way onto Arch, so far it has made theming the panel much easier. Having most of the applets using GTK3 now makes it a lot easier to fine tune things that I couldn't with the GTK2 applets.
@matthewmx86 I've updated the panelbar theming documentation for 4.14. If there are other plugins you could think of including I'll might add examples for them too; however I'm only targeting the more common plugins that are often asked about.
@mknepper I've tested the theme on 4.14 and it looks good. Libreoffice still didn't look so happy though.I used a back-ported version of XFCE 4.14 on an XUbuntu 19.04 desktop to test. The version of desktop environment shouldn't affect other GTK3 applications. I'm still looking into it, however I only have time on the weekends.
Just a general update. I have combobox button arrows working, scrollbar buttons working, and looking into spinbuttons right now.
Also thinking of changing how combobox menus appear so hopefully they will be a little more consistent. I'll push the changes later to the staging branch for some testing.
4.14 made it's way onto Arch, so far it has made theming the panel much easier. Having most of the applets using GTK3 now makes it a lot easier to fine tune things that I couldn't with the GTK2 applets.
Ah, interesting. I would love to see that make its way into Redmond2K that you've created.
Just a general update. I have combobox button arrows working, scrollbar buttons working, and looking into spinbuttons right now.
Also thinking of changing how combobox menus appear so hopefully they will be a little more consistent. I'll push the changes later to the staging branch for some testing.
Okay, awesome. I wasn't sure how having Xfce 4.14 use 100% GTK3 was going to affect development of this theme. Thanks for the update. You do great work and I'm jealous I'm not as smart as you. Is there some way we can donate to this project, by the way?
@mknepper Thank you! You would have to ask @grassmunk about donations and such since grassmunk owns this github repo.
OK try it out now. I have it on the Staging branch at the moment. I had to revert the previous commit since i forgot to update Staging to match Master, but everything is there now.
Here are some screenshots taken from my XUbuntu 18.04 system (it will look identical on 19.04 as well):
Since the combobox buttons in LO don't appear to support pseudo classes, I can't style the buttons to have a toggle / check / active state. The arrow icons also appear poorly scaled, but it's better than before.
Scrollbox buttons in LO are also functioning at-last. I don't think there's any theme that exists aside from @matthewmx86 Redmon97 theme that has functioning scrollbox buttons in LO. I did go about it a little differently though so that the size and positioning were accurate to the 16px X 16px rule.
Spinbuttons (those little boxes with the positive and minus) and spinbutton entries should also look much better. I kept the entry background as bg_color instead of just white, because the way to setup those buttons is an absolute hack that relies on the spinbutton background colour.
I was wanting to change the combobox menus to just a white background with a 1px black border, however CSD decorations will always override it. I can't do away with CSD decorations because it will affect new-age GTK3+ applications that rely on the decoration class to set the application border.
I also made some additional changes that weren't related to the LO fixes.
Wow that looks good! Going to test it out later today.
As a general update, I will be merging changes applied in the staging branch into the master branch soon.
Distro: Xubuntu 18.04 LTS DE: Xfce 4.12 LibreofficeVersion: 6.0.7.3
Just thought I'd let you know.