Skip to content

Allow Setting Window Title - #806

Merged
raphamorim merged 6 commits into
raphamorim:mainfrom
xsadia:feat/add-title-arg
Nov 20, 2024
Merged

Allow Setting Window Title#806
raphamorim merged 6 commits into
raphamorim:mainfrom
xsadia:feat/add-title-arg

Conversation

@xsadia

@xsadia xsadia commented Nov 20, 2024

Copy link
Copy Markdown
Contributor

This PR adds support for specifying a custom window title using the --title argument in the CLI. This feature allows users to define a specific name for the window, improving usability in multi-window setups and enabling better integration with window managers.

Default window title

image

Custom name with --title flag

image

closes #405

Comment thread rio-backend/src/config/window.rs Outdated
#[serde(default = "bool::default", rename = "macos-use-unified-titlebar")]
pub macos_use_unified_titlebar: bool,
#[serde(skip_serializing)]
pub title: Option<String>,

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

can we rename it for title_placeholder or initial_title ?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Sure! Will change

@raphamorim

Copy link
Copy Markdown
Owner

Overall it looks good! thanks for the PR @xsadia I appreciate!

Would you mind also to include it in the docs?

@xsadia

xsadia commented Nov 20, 2024

Copy link
Copy Markdown
Contributor Author

Overall it looks good! thanks for the PR @xsadia I appreciate!

Would you mind also to include it in the docs?

Absolutely, I'll update the docs as well shortly!

@xsadia

xsadia commented Nov 20, 2024

Copy link
Copy Markdown
Contributor Author

@raphamorim anything else you'd like me to change just let me know!

@raphamorim

Copy link
Copy Markdown
Owner

Thank you @xsadia 🙏 ⭐

Comment thread rio-backend/src/config/window.rs Outdated
pub decorations: Decorations,
#[serde(default = "bool::default", rename = "macos-use-unified-titlebar")]
pub macos_use_unified_titlebar: bool,
#[serde(skip_serializing)]

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

just one small thing: add rename = "initial-title"

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

@raphamorim raphamorim left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

🚀

@raphamorim
raphamorim merged commit 3c2cb57 into raphamorim:main Nov 20, 2024
@raphamorim

Copy link
Copy Markdown
Owner

@xsadia feel free to join our discord :) https://discord.gg/zRvJjmKGwS

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.

Feature Request: Allow Setting Window Class and/or Title

2 participants