Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Separate separator colour from border OR border bug? #1019

Closed
avaskoog opened this issue Feb 12, 2017 · 7 comments
Closed

Separate separator colour from border OR border bug? #1019

avaskoog opened this issue Feb 12, 2017 · 7 comments
Labels

Comments

@avaskoog
Copy link

avaskoog commented Feb 12, 2017

Yo!

I may have messed up completely, but all my windows lack the show-border flag, and I have deleted all ImGui save/config/ini files and I have added the no-save flag to all windows as well. Yet I still see borders no matter what. Considering there's an option to show borders rather than hide them, shouldn't the default be no borders? How come I'm seeing borders?

My hacky solution so far has been to just set the theme's style's border colour to have an alpha value of zero, but that comes with my particular issue right now: I want a borderless layout, but since the only way I've managed to get rid of borders is to set the alpha to zero, and horizontal separators (Separator()) in menus use the same colour style, my separators are now invisible, and I would like to see those despite having a borderless theme...

So unless there is some show-border issue to be solved (either because there is a bug or because I made some kind of mistake), I guess it would be nice to have separator colour be separate from border colour, since I want to hide the borders but not the separators.

c:

@ocornut
Copy link
Owner

ocornut commented Feb 12, 2017 via email

@avaskoog
Copy link
Author

Aahh. Yes. I had actually touched that flag before to try and be smart about it in some way before, and had just forgotten about it.

But the attempt at smartness comes from the other issue you bring up (apparently I had been setting the flag depending on the alpha value of the colour as an ad-hoc solution, which broke down when it got to the separators now), which is that whether or not to have borders is not currently AFAIK a style/theme setting, so yes, that'd be a good addition indeed! c:

@avaskoog
Copy link
Author

Am I mistaken, or is it true that there is still no way to get rid of menubar borders other than setting the alpha to zero? I managed to get rid of the windows' borders now but the menu popups still have borders and I can't find any boolean flag in those functions.

@ocornut
Copy link
Owner

ocornut commented Feb 12, 2017

Yes you are correct, this should be reworked when I get to do a pass on all border settings.

@avaskoog
Copy link
Author

All right, thanks for the sanity check!

@ocornut ocornut added the style label Aug 8, 2017
ocornut added a commit that referenced this issue Aug 14, 2017
@ocornut
Copy link
Owner

ocornut commented Aug 14, 2017

@avaskoog I have now applied the (breaking) change of renaming the ImGuiCol_Column_XXX enums to ImGuiCol_Separator_XXX.
Columns() and Separator() now uses that colors.

I think it should fix the issue "Separate separator colour from border".
I am working on moving the Border to the style structure as float BorderSize and removing the ShowBorder flag as well. This is a slightly more tricky change, I'll commit it along with improvements related to #707

ocornut added a commit that referenced this issue Nov 19, 2017
…rs are now fully set up in the ImGuiStyle structure (see e.g. style.FrameBorderSize, style.WindowBorderSize). Use ImGui::ShowStyleEditor() to look them up. (#707, fix #819, #1031, ref #1019, ref #447)
@ocornut
Copy link
Owner

ocornut commented Nov 19, 2017

@avaskoog Now pushed a handful of changes today so you can now freely alter the border size style.WindowBorderSize, style.FrameBorderSize style.PopupBorderSize, independently.
See functions such as ImGui::PushStyleVar(ImGuiStyleVar_FrameBorderSize, 1.0f).
The ImGuiWindowFlags_ShowBorders flag has been completely obsoleted.

Let me know if that all works as expected for you!

@ocornut ocornut closed this as completed Aug 17, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants