File tree Expand file tree Collapse file tree 4 files changed +61
-1
lines changed
ricaun.AutoCAD.UI.Example Expand file tree Collapse file tree 4 files changed +61
-1
lines changed Original file line number Diff line number Diff line change @@ -4,6 +4,14 @@ All notable changes to this project will be documented in this file.
4
4
The format is based on [ Keep a Changelog] ( http://keepachangelog.com/en/1.0.0/ )
5
5
and this project adheres to [ Semantic Versioning] ( http://semver.org/spec/v2.0.0.html ) .
6
6
7
+ ## [ 0.4.0] / 2025-07-18
8
+ ### Features
9
+ - Support ` AddSlideOut ` extension.
10
+ - Support ` SetDialogLauncher ` and ` GetDialogLauncher ` extensions.
11
+ ### UI
12
+ - Update ` RibbonExtension ` to support ` AddSlideOut ` .
13
+ - Update ` RibbonExtension ` to support ` SetDialogLauncher ` and ` GetDialogLauncher ` .
14
+
7
15
## [ 0.3.0] / 2025-07-15
8
16
### Features
9
17
- Support ` CreateSplitButton ` extension.
@@ -46,6 +54,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
46
54
- Add ` Busy ` , ` Runtime ` , ` Tasks ` , and ` Windows ` utilities.
47
55
48
56
[ vNext ] : ../../compare/1.0.0...HEAD
57
+ [ 0.4.0 ] : ../../compare/0.3.0...0.4.0
49
58
[ 0.3.0 ] : ../../compare/0.2.0...0.3.0
50
59
[ 0.2.0 ] : ../../compare/0.1.0...0.2.0
51
60
[ 0.1.0 ] : ../../compare/0.1.0
Original file line number Diff line number Diff line change 1
1
<Project >
2
2
<PropertyGroup >
3
- <Version >0.3.0 </Version >
3
+ <Version >0.4.0-alpha </Version >
4
4
</PropertyGroup >
5
5
</Project >
Original file line number Diff line number Diff line change @@ -116,6 +116,18 @@ await autoCADTask.Run(() =>
116
116
. SetLargeImage ( "Resources/Cube-Green-Light.tiff" )
117
117
. SetDescription ( "This is a PulldownButton" ) ;
118
118
119
+ ribbonPanel . AddSlideOut ( ) ;
120
+ ribbonPanel . RowStackedItems (
121
+ ribbonPanel . CreateButton ( "1" )
122
+ . SetLargeImage ( "Resources/Cube-Grey-Light.tiff" ) ,
123
+ ribbonPanel . CreateButton ( "2" )
124
+ . SetLargeImage ( "Resources/Cube-Grey-Light.tiff" ) ,
125
+ ribbonPanel . CreateButton ( "3" )
126
+ . SetLargeImage ( "Resources/Cube-Grey-Light.tiff" )
127
+ ) ;
128
+
129
+ ribbonPanel . SetDialogLauncher ( ribbonPanel . CreateButton ( "DialogLauncher" ) . SetCommand ( e => Windows . MessageBox . ShowMessage ( e . Text ) ) ) ;
130
+
119
131
ribbonControl . ActiveTab = ribbonPanel . Tab ;
120
132
}
121
133
public override void OnShutdown ( RibbonControl ribbonControl )
Original file line number Diff line number Diff line change @@ -522,6 +522,45 @@ public static RibbonPanel AddSeparator(this RibbonPanel ribbonPanel)
522
522
return ribbonPanel ;
523
523
}
524
524
525
+ /// <summary>
526
+ /// Adds a slide-out (panel break) to the ribbon panel.
527
+ /// </summary>
528
+ /// <param name="ribbonPanel">The ribbon panel to extend.</param>
529
+ /// <returns>The ribbon panel with the slide-out added.</returns>
530
+ public static RibbonPanel AddSlideOut ( this RibbonPanel ribbonPanel )
531
+ {
532
+ if ( ribbonPanel is null ) return ribbonPanel ;
533
+ ribbonPanel . AddItem ( new RibbonPanelBreak ( ) ) ;
534
+ return ribbonPanel ;
535
+ }
536
+
537
+ /// <summary>
538
+ /// Sets the dialog launcher for the specified <see cref="RibbonPanel"/>.
539
+ /// </summary>
540
+ /// <param name="ribbonPanel">The ribbon panel to set the dialog launcher for.</param>
541
+ /// <param name="ribbonItem">The <see cref="RibbonCommandItem"/> to use as the dialog launcher.</param>
542
+ /// <returns>The <see cref="RibbonPanel"/> with the dialog launcher set.</returns>
543
+ public static RibbonPanel SetDialogLauncher ( this RibbonPanel ribbonPanel , RibbonCommandItem ribbonItem )
544
+ {
545
+ if ( ribbonPanel is null ) return ribbonPanel ;
546
+ ribbonPanel . Source . DialogLauncher = ribbonItem ;
547
+ ribbonPanel . Remove ( ribbonItem ) ;
548
+ return ribbonPanel ;
549
+ }
550
+
551
+ /// <summary>
552
+ /// Gets the dialog launcher <see cref="RibbonCommandItem"/> for the specified <see cref="RibbonPanel"/>.
553
+ /// </summary>
554
+ /// <param name="ribbonPanel">The ribbon panel to retrieve the dialog launcher from.</param>
555
+ /// <returns>
556
+ /// The <see cref="RibbonCommandItem"/> set as the dialog launcher for the panel, or <c>null</c> if the panel is <c>null</c>.
557
+ /// </returns>
558
+ public static RibbonCommandItem GetDialogLauncher ( this RibbonPanel ribbonPanel )
559
+ {
560
+ if ( ribbonPanel is null ) return null ;
561
+ return ribbonPanel . Source . DialogLauncher ;
562
+ }
563
+
525
564
#region RibbonListButton
526
565
527
566
/// <summary>
You can’t perform that action at this time.
0 commit comments