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

Hide separator between titlebar and content #91

Merged
merged 1 commit into from
Mar 12, 2023

Conversation

head-gardener
Copy link
Contributor

@head-gardener head-gardener commented Jan 10, 2023

Solves #70.
Toggled via titlebar_separator enable|disable, where disable hides the border.

image

@WillPower3309
Copy link
Owner

Good stuff! Before I can merge this I'll have to request that you match the indentation

@head-gardener head-gardener force-pushed the separate_titlebar branch 2 times, most recently from f174661 to a0caaf8 Compare January 11, 2023 07:13
@head-gardener
Copy link
Contributor Author

Thought i fixed that earlier. Should be ok now.

Copy link
Owner

@WillPower3309 WillPower3309 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Just one more indentation fix needed

@head-gardener
Copy link
Contributor Author

Done. Thanks for your patience.

@WillPower3309
Copy link
Owner

Thanks for all the work here! Finally have some time today to do some testing with this branch, stay tuned :)

@RicArch97
Copy link
Contributor

Thanks for the implementation. For the command we could think about changing to separate_titlebar_border command as it specifically applies to the border, or perhaps titlebar_border_separator yes|no as we should make clear what this does, remove the border between the view and titlebar.

@head-gardener
Copy link
Contributor Author

Second one seems to be more intuitive.

@WillPower3309
Copy link
Owner

Just wanted to say this will definitely get merged but I'd like to fix #96 first before making any other changes to render.c

@head-gardener head-gardener force-pushed the separate_titlebar branch 3 times, most recently from 5190d60 to 9b7915b Compare March 6, 2023 16:27
@RicArch97
Copy link
Contributor

RicArch97 commented Mar 11, 2023

Just tested this PR and got about half a transparent line of pixels on left side my alacritty window;

2023-03-11T05:28:03,635515191+01:00

@WillPower3309 Any idea if this has something do with the other effects (shadows / rounded corners)? Can't really see how these changes would cause this.

@RicArch97
Copy link
Contributor

RicArch97 commented Mar 11, 2023

You should probably add an entry of the new option to the man page.

I also suggest to change the option values to enable/disable instead of yes/no it's more in line with the rest of Sway's boolean options.

@head-gardener
Copy link
Contributor Author

head-gardener commented Mar 11, 2023

Any idea if this has something do with the other effects (shadows / rounded corners)? Can't really see how these changes would cause this.

This PR just prevents sway from rendering lower title bar border, so if it doesn't scale background elements correctly some areas will become empty. Issue on your screenshot is with the left pad, which I must have missed because my title textures where aligned to the left. Going to check now to see if that's the problem.

You should probably add an entry of the new option to the man page.

Honestly I've missed that we had one. Right on it.

I also suggest to change the option values to enable/disable instead of yes/no it's more in line with the rest of Sway's boolean options.

Should have done that with the last commit.

@head-gardener
Copy link
Contributor Author

@RicArch97 can you confirm the issue is fixed?

Copy link
Contributor

@RicArch97 RicArch97 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left a few more comments, rest LGTM

sway/commands/titlebar_separator.c Outdated Show resolved Hide resolved
sway/desktop/render.c Outdated Show resolved Hide resolved
sway/sway.5.scd Outdated Show resolved Hide resolved
@RicArch97
Copy link
Contributor

In terms of functionality it's good now. Here's an updated screenshot:

2023-03-12T03:58:01,237501836+01:00

@WillPower3309 WillPower3309 merged commit ac31a61 into WillPower3309:master Mar 12, 2023
@head-gardener head-gardener deleted the separate_titlebar branch March 12, 2023 07:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Borders: ability to configure a border color around windows when using title bars, without a line inbetween
3 participants