Ribbon for WinForms
トグルボタン
要素 > リボンアイテム > トグルボタン

A toggle button is a command button that allows the user to switch between two states. When a user clicks on a toggle button, it switches to the pressed/active state and on consecutive clicking, it returns back to the unpressed/inactive state.

The GIF below shows a toggle button with tooltip:

The Toggle Button can be added at design-time using the Floating Toolbar or Collection Editor. Refer this topic for detailed information. A toggle button can also be added to the C1Ribbon control through the code using the RibbonToggleButton class. This is depicted in the code below.

' フォーマットグループにトグルボタンを追加します
Dim leftAlign As RibbonToggleButton = New RibbonToggleButton(Image.FromFile("images\align_left.png"))
leftAlign.ToolTip = "Align your content with left margin."
formatGroup.Items.Add(leftAlign)
// フォーマットグループにトグルボタンを追加します
RibbonToggleButton leftAlign = new RibbonToggleButton(Image.FromFile(@"images\align_left.png"));
leftAlign.ToolTip = "Align your content with left margin.";
formatGroup.Items.Add(leftAlign);