Skip to content

Commit 5255beb

Browse files
committed
Menus and Shortcuts: stylistic changes for MenuElement
Update documentation and style for `MenuElement`.
1 parent e32fe60 commit 5255beb

File tree

1 file changed

+10
-8
lines changed

1 file changed

+10
-8
lines changed

Sources/SwiftWin32/Menus and Shortcuts/MenuElement.swift

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -37,29 +37,31 @@ extension MenuElement {
3737
/// Constants that indicate the state of an action-based or command-based
3838
/// menu element.
3939
public enum State: Int {
40-
/// A constant indicating the menu element is in the "off" state.
41-
case off
40+
/// A constant indicating the menu element is in the "off" state.
41+
case off
4242

43-
/// A constant indicating the menu element is in the "on" state.
44-
case on
43+
/// A constant indicating the menu element is in the "on" state.
44+
case on
4545

46-
/// A constant indicating the menu element is in the "mixed" state.
47-
case mixed
46+
/// A constant indicating the menu element is in the "mixed" state.
47+
case mixed
4848
}
4949
}
5050

5151
/// An object representing a menu, action, or command.
5252
public class MenuElement {
53-
/// Getting the Element Attributes
53+
// MARK - Getting the Element Attributes
5454

5555
/// The title of the menu element.
5656
public internal(set) var title: String
5757

5858
/// The image to display alongside the menu element's title.
5959
public internal(set) var image: Image?
6060

61-
/// Creating a Menu Element
61+
// MARK - Creating a Menu Element
6262

63+
/// Creates and returns a `MenuElement` initialized with the given title and
64+
/// image.
6365
public init(title: String, image: Image? = nil) {
6466
self.title = title
6567
self.image = image

0 commit comments

Comments
 (0)