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

Implement a new type of separator for creating a menu with multiple columns. #59

Closed
end2endzone opened this issue Jul 27, 2020 · 3 comments
Labels
enhancement New feature or request
Milestone

Comments

@end2endzone
Copy link
Owner

Windows support multiple type of separator, one of them is a column separator which forces a menu item to be displayed on a new column.

The flags MENUBARBREAK or MENUBREAK can be used to create column menu.

See https://docs.microsoft.com/en-us/windows/win32/menurc/menuitem-statement for details.

The suggested implementation in a configuration file may look something like this:

<menu separator="true" type="column" />

By default, the value of the type attribute should be horizontal, therefore, the following would created a legacy separator:

<menu separator="true" type="horizontal" />
@end2endzone end2endzone added the enhancement New feature or request label Jul 27, 2020
@end2endzone end2endzone changed the title Implement a new type of separator for creating a menu with multiple column. Implement a new type of separator for creating a menu with multiple columns. Jul 27, 2020
@end2endzone
Copy link
Owner Author

Documentation for popup menus: https://docs.microsoft.com/en-us/windows/win32/menurc/popup-resource

@end2endzone
Copy link
Owner Author

Here is a code example that show how to create a second column in a popup menu: demo_popup_menu.zip. It seems that the new column flag must be added to a valid (clickable) element as opposed to a normal separator.

@end2endzone
Copy link
Owner Author

Using type attribute for a separator might not be the best idea. A type attribute should be more suited for a different type of menu.

Another implementation could be to expand the separator attribute to allow values such as horizontal, column and vertical. For example:

<menu separator="true" />
<menu separator="horizontal" />
<menu separator="column" />
<menu separator="vertical" />
```

end2endzone added a commit that referenced this issue Nov 7, 2021
@end2endzone end2endzone added this to the 0.7.0 milestone Dec 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant