Hide Table of Contents
SOLIDWORKS Electrical API 2023.0.0
Electrical API
EwApplicationRibbon.idl
Go to the documentation of this file.
1#pragma once
2
3#if (__midl >= 501)
4midl_pragma warning(disable:2111) /* Disable warning MIDL2111 regarding identifier lengths exceeding 31 chars. */
5#endif
6
7import "oaidl.idl";
8import "ocidl.idl";
9import "EnumDefinition.idl";
10
11
16[
17 object,
18 uuid(FEF554E8-F0B8-4397-850B-A6F63A921B0A),
19 dual,
20 nonextensible,
21 pointer_default(unique)
22]
23interface IEwRibbonComboBoxControlX : IDispatch
24{
33
34
43 int getSelectedIndex (EwErrorCode* errorCode);
44
45
55
56
65 EwErrorCode addItemText (BSTR strItemText);
66
67
77 EwErrorCode addItemTextAt (int iIndex, BSTR strItemText);
78
79
90 int findText (int iIndexStart, BSTR strFindItemText, EwErrorCode* errorCode);
91
92
102
103
112 int getItemCount (EwErrorCode* errorCode);
113
114
123 BSTR getSelectedText (EwErrorCode* errorCode);
124
125
134 BSTR getEditText (EwErrorCode* errorCode);
135
136
145 EwErrorCode setEditText (BSTR strEditText);
146
147
156 BSTR getEditHintText (EwErrorCode* errorCode);
157
158
167 EwErrorCode setEditHintText (BSTR strHintText);
168
169
178 EwErrorCode enableAutoComplete (VARIANT_BOOL bAutoComplete);
179
180
190 ULONGLONG getItemData (int iIndex, EwErrorCode* errorCode);
191
192
202 EwErrorCode setItemData (int iIndex, ULONGLONG pItemData);
203
204};
205
210[
211 object,
212 uuid(30E4BDC2-FF3F-490A-BF15-52332FA7CFEF),
213 dual,
214 nonextensible,
215 pointer_default(unique)
216]
217interface IEwRibbonControlX : IDispatch
218{
227 BSTR getCaption (EwErrorCode* errorCode);
228
229
230
239 EwErrorCode setCaption (BSTR strCaption);
240
241
250 BSTR getToolTip (EwErrorCode* errorCode);
251
252
253
262 EwErrorCode setToolTip (BSTR strToolTip);
263
264
273 BSTR getDescription (EwErrorCode* errorCode);
274
275
276
285 EwErrorCode setDescription (BSTR strDescription);
286
287
296 VARIANT_BOOL isVisible (EwErrorCode* errorCode);
297
298
307 EwErrorCode setVisible (VARIANT_BOOL bVisible);
308
309
318 VARIANT_BOOL isEnabled (EwErrorCode* errorCode);
319
320
330 EwErrorCode setEnabled (VARIANT_BOOL bEnabled);
331
332
341 VARIANT_BOOL isBeginGroup (EwErrorCode* errorCode);
342
343
352 EwErrorCode setBeginGroup (VARIANT_BOOL bBeginGroup);
353
354
363 BSTR getShortcutText (EwErrorCode* errorCode);
364
365
374 EwErrorCode setShortcutText (BSTR strShortcutText);
375
376
388 EwErrorCode setIconFromImage (BSTR strImageFilePath, EwRibbonButtonSize eRibbonButtonSize , COLORREF crMask);
389
390
400
401
412
413
422 long getID (EwErrorCode* errorCode);
423
424
434 BSTR getCommand (EwErrorCode* errorCode);
435
436
446 EwErrorCode setCommand (BSTR strCommand);
447
448
464 IEwRibbonControlX addControl (EwRibbonControlType eRibbonControlType, BSTR strCommand, EwErrorCode* errorCode);
465
466
476 VARIANT_BOOL getCheck (EwErrorCode* errorCode);
477
478
488 EwErrorCode setCheck (VARIANT_BOOL bCheck);
489
490
502
503
513 int getIndex (EwErrorCode* errorCode);
514
515
529 BSTR getCategory (EwErrorCode* errorCode);
530
531
545 EwErrorCode setCategory (BSTR strCategory);
546
547
557 VARIANT_BOOL isOnQuickAccess (EwErrorCode* errorCode);
558
559
569 EwErrorCode setOnQuickAccess (VARIANT_BOOL bOnQuickAccess);
570
571
572
584
585};
586
587
592[
593 object,
594 uuid(779E10A8-9370-4F87-9EE7-FD051EF33DA7),
595 dual,
596 nonextensible,
597 pointer_default(unique)
598]
599interface IEwRibbonGroupX : IDispatch
600{
609 BSTR getCaption (EwErrorCode* errorCode);
610
611
612
621 EwErrorCode setCaption (BSTR strCaption);
622
623
637 IEwRibbonControlX addControl (EwRibbonControlType eRibbonControlType, BSTR strCommand, EwErrorCode* errorCode);
638
639
640
652
653
662 int getControlCount (EwErrorCode* errorCode);
663
664
675
676
685
686
695 long getID (EwErrorCode* errorCode);
696
697
698
716 IEwRibbonControlX insertControl (int nPosition, EwRibbonControlType eRibbonControlType, BSTR strCommand, EwErrorCode* errorCode);
717
718
731
732
744
745
755 int getIndex (EwErrorCode* errorCode);
756
757
770 VARIANT_BOOL getControlsGrouping (EwErrorCode* errorCode);
771
772
785 EwErrorCode setControlsGrouping (VARIANT_BOOL bControlsGrouping);
786
787
797 VARIANT_BOOL getControlsCentering (EwErrorCode* errorCode);
798
799
809 EwErrorCode setControlsCentering (VARIANT_BOOL bControlsCentering);
810
811
825 EwErrorCode setAllowReduce (EwRibbonGroupReductionLevels eRibbonGroupReductionLevels);
826
827
842 EwRibbonGroupReductionLevels getAllowReduce (EwErrorCode* errorCode);
843
844};
845
850[
851 object,
852 uuid(16767327-DD46-4EA7-AD9A-0844E008A4B2),
853 dual,
854 nonextensible,
855 pointer_default(unique)
856]
857interface IEwRibbonTabX : IDispatch
858{
867 BSTR getCaption (EwErrorCode* errorCode);
868
869
870
879 EwErrorCode setCaption (BSTR strCaption);
880
881
891 IEwRibbonGroupX addGroup (BSTR strCaption, EwErrorCode* errorCode);
892
893
905 IEwRibbonGroupX insertGroup (BSTR strCaption, int iIndex, EwErrorCode* errorCode);
906
907
918 IEwRibbonGroupX getGroupAt (int iIndex, EwErrorCode* errorCode);
919
920
929 int getGroupCount (EwErrorCode* errorCode);
930
931
932
943
944
953
954
963 VARIANT_BOOL isVisible (EwErrorCode* errorCode);
964
965
974 EwErrorCode setVisible (VARIANT_BOOL bVisible);
975
976
977
986 VARIANT_BOOL isEnabled (EwErrorCode* errorCode);
987
988
998 EwErrorCode setEnabled (VARIANT_BOOL bEnabled);
999
1000
1009 long getID (EwErrorCode* errorCode);
1010
1011
1020 EwErrorCode remove ();
1021
1022
1032 int getIndex (EwErrorCode* errorCode);
1033
1034};
1035
1040[
1041 object,
1042 uuid(da667cd1-2b49-4144-84b4-99c27502ee1a),
1043 dual,
1044 nonextensible,
1045 pointer_default(unique)
1046]
1047interface IEwRibbonQuickAccessControlX : IDispatch
1048{
1059 IEwRibbonControlX findControlByID (int iControlId, EwErrorCode* errorCode);
1060
1061
1071
1072
1086 IEwRibbonControlX addControl (EwRibbonControlType eRibbonControlType, BSTR strCommand, EwErrorCode* errorCode);
1087
1088
1100
1101
1111
1112
1124
1125
1134
1135
1152 IEwRibbonControlX insertControlAt (int iIndex, EwRibbonControlType eRibbonControlType, BSTR strCommand, EwErrorCode* errorCode);
1153
1154
1166
1167
1176
1177
1189
1190
1201
1202
1216 IEwRibbonControlX addRibbonControl (int iControlID, EwRibbonControlType eType, BSTR strCommand, EwErrorCode* errorCode);
1217
1218
1219
1230
1231};
1232
1237[
1238 object,
1239 uuid(424CCD51-1FDC-4CC5-83C3-D9D42A8376D4),
1240 dual,
1241 nonextensible,
1242 pointer_default(unique)
1243]
1244interface IEwRibbonX : IDispatch
1245{
1255 IEwRibbonTabX addTab (BSTR strCaption, EwErrorCode* errorCode);
1256
1257
1268 IEwRibbonTabX insertTab (BSTR strCaption, int iIndex, EwErrorCode* errorCode);
1269
1270
1271
1281
1282
1283
1294
1295
1306 IEwRibbonTabX getTabAt (int iIndex, EwErrorCode* errorCode);
1307
1308
1317 int getTabCount (EwErrorCode* errorCode);
1318
1319
1320
1331
1332
1345
1346
1359
1360
1371
1372
1373};
EwRibbonButtonSize
Ribbon bar button's styles.
Definition: EnumDefinition.idl:265
EwRibbonButtonStyle
Ribbon bar button's styles.
Definition: EnumDefinition.idl:249
EwRibbonControlType
Type of the control that can be used in a ribbon.
Definition: EnumDefinition.idl:228
EwRibbonMainTabType
Enum used to get main tabs of ribbon of the Application.
Definition: EnumDefinition.idl:361
EwErrorCode
All errors codes for this API.
Definition: EnumDefinition.idl:21
Use this interface to manage the ComboBox control on Ribbon.
Definition: EwApplicationRibbon.idl:24
EwErrorCode setSelectedIndex(int iIndex)
Set the index of the item to be selected in the ComboBox.
int findText(int iIndexStart, BSTR strFindItemText, EwErrorCode *errorCode)
Find a text item in the ComboBox.
EwErrorCode setItemData(int iIndex, ULONGLONG pItemData)
Set the item data value associated with the specified combo box item.
BSTR getSelectedText(EwErrorCode *errorCode)
Return the selected item text from the ComboBox.
EwErrorCode addItemText(BSTR strItemText)
Add text item to the ComboBox.
EwErrorCode setEditText(BSTR strEditText)
Set the edit text.
EwErrorCode addItemTextAt(int iIndex, BSTR strItemText)
Add text item to the ComboBox at a specific position or index.
BSTR getEditText(EwErrorCode *errorCode)
Get the edit text.
int getItemCount(EwErrorCode *errorCode)
Return the number of items in this ComboBox.
EwErrorCode removeContent()
Removes all items from the ComboBox.
int getSelectedIndex(EwErrorCode *errorCode)
Get the index of the current selected item in the ComboBox.
EwErrorCode enableAutoComplete(VARIANT_BOOL bAutoComplete)
Enables or disables auto completion.
EwErrorCode setEditHintText(BSTR strHintText)
Set grayed-out text displayed in the edit control that displayed a helpful description of what the co...
BSTR getEditHintText(EwErrorCode *errorCode)
Get grayed-out text displayed in the edit control that displayed a helpful description of what the co...
ULONGLONG getItemData(int iIndex, EwErrorCode *errorCode)
Get the item data value associated with the specified combo box item.
EwErrorCode deleteItemAt(int iIndex)
Delete a text item from the ComboBox.
Use this interface to manage the control on Ribbon tab.
Definition: EwApplicationRibbon.idl:218
EwErrorCode setCheck(VARIANT_BOOL bCheck)
Check or uncheck the control.
long getID(EwErrorCode *errorCode)
Get the Id's of control.
EwErrorCode setStyle(EwRibbonButtonStyle eRibbonButtonStyle)
Set the style of the control.
EwRibbonButtonStyle getStyle(EwErrorCode *errorCode)
Get the control's style.
EwErrorCode setIconFromImage(BSTR strImageFilePath, EwRibbonButtonSize eRibbonButtonSize, COLORREF crMask)
Add an icon from file.
BSTR getCaption(EwErrorCode *errorCode)
Return the caption of this control.
VARIANT_BOOL isOnQuickAccess(EwErrorCode *errorCode)
Get whether the control is a part of Quick access panel.
EwErrorCode setVisible(VARIANT_BOOL bVisible)
Hide or show the control.
BSTR getCategory(EwErrorCode *errorCode)
Return the category of the control.
EwErrorCode setDescription(BSTR strDescription)
Set a description for this control.
EwErrorCode setEnabled(VARIANT_BOOL bEnabled)
Set whether the control is enabled.
int getIndex(EwErrorCode *errorCode)
Return the index of the control.
EwErrorCode setCommand(BSTR strCommand)
Set the name of the command associated with this ribbon control.
EwErrorCode setOnQuickAccess(VARIANT_BOOL bOnQuickAccess)
Set whether the control is a part of Quick access panel.
VARIANT_BOOL isEnabled(EwErrorCode *errorCode)
Determine if the control is enabled.
EwRibbonControlType getControlType(EwErrorCode *errorCode)
Get the control's Type.
BSTR getDescription(EwErrorCode *errorCode)
Return the description of this control.
BSTR getShortcutText(EwErrorCode *errorCode)
Get the control's shortcut.
VARIANT_BOOL isVisible(EwErrorCode *errorCode)
Determine if the control is visible.
VARIANT_BOOL isBeginGroup(EwErrorCode *errorCode)
Determine if the control is a separator.
BSTR getToolTip(EwErrorCode *errorCode)
Return the ToolTip of this control.
VARIANT_BOOL getCheck(EwErrorCode *errorCode)
Determine if the control is checked.
EwErrorCode setCategory(BSTR strCategory)
Set a category for the control.
IEwRibbonControlX addControl(EwRibbonControlType eRibbonControlType, BSTR strCommand, EwErrorCode *errorCode)
Add a new control to a pop-up button.
EwErrorCode setShortcutText(BSTR strShortcutText)
Set the shortcut string of the control.
BSTR getCommand(EwErrorCode *errorCode)
Return the text of parameter strCommand used when calling EwRibbonGroupX::addControl.
IEwRibbonComboBoxControlX addComboBoxControl(EwErrorCode *errorCode)
Add the ComboBox Control in the pop-up button ribbon control.
EwErrorCode setBeginGroup(VARIANT_BOOL bBeginGroup)
Begin a new group using a separator.
EwErrorCode setToolTip(BSTR strToolTip)
Set a new ToolTip for this control.
EwErrorCode setCaption(BSTR strCaption)
Set a new caption for this control.
Use this interface to manage the Ribbon group.
Definition: EwApplicationRibbon.idl:600
EwRibbonGroupReductionLevels getAllowReduce(EwErrorCode *errorCode)
Get the current reduce level for the ribbon group.
EwErrorCode setControlsGrouping(VARIANT_BOOL bControlsGrouping)
Group buttons in the group, false by default.
BSTR getCaption(EwErrorCode *errorCode)
Return the caption of this ribbon group.
EwErrorCode removeControl(int iIndex)
Remove a control specified by the index.
EwErrorCode setCaption(BSTR strCaption)
Set a new caption for this ribbon group.
IEwRibbonControlX getControlAt(int iIndex, EwErrorCode *errorCode)
Return the specified control of the current group.
EwErrorCode removeAll()
Remove all controls.
IEwRibbonComboBoxControlX insertComboBoxControl(int nPosition, EwErrorCode *errorCode)
Insert the ComboBox Control in the Ribbon Group.
long getID(EwErrorCode *errorCode)
Get the Id's of group.
VARIANT_BOOL getControlsGrouping(EwErrorCode *errorCode)
Determines if control grouping is used.
IEwRibbonControlX insertControl(int nPosition, EwRibbonControlType eRibbonControlType, BSTR strCommand, EwErrorCode *errorCode)
Insert a new control to a pop-up button in a ribbon.
EwErrorCode setAllowReduce(EwRibbonGroupReductionLevels eRibbonGroupReductionLevels)
Set this method to prevent group to be reduced.
int getIndex(EwErrorCode *errorCode)
Return the index of the group.
VARIANT_BOOL getControlsCentering(EwErrorCode *errorCode)
Determine if controls are automatically center in group.
EwErrorCode setControlsCentering(VARIANT_BOOL bControlsCentering)
Automatically center controls in group, false by default.
IEwRibbonControlX addControl(EwRibbonControlType eRibbonControlType, BSTR strCommand, EwErrorCode *errorCode)
Add a new control at the end of the ribbon group.
IEwRibbonComboBoxControlX addComboBoxControl(EwErrorCode *errorCode)
Add the ComboBox Control in the Ribbon Group.
int getControlCount(EwErrorCode *errorCode)
Return the number of control in the current group.
Use this interface to manage the quick access control on Ribbon.
Definition: EwApplicationRibbon.idl:1048
EwErrorCode resetQuickAccessToolbar()
Resets default controls in Quick Access Toolbar.
EwErrorCode removeControlByID(int iControlID)
Remove a control specified by the ID in Quick Access Toolbar.
IEwRibbonComboBoxControlX insertComboBoxControl(int nPosition, EwErrorCode *errorCode)
Insert the ComboBox Control in Quick Access Toolbar.
EwErrorCode removeAll()
Remove all controls from Quick Access Toolbar.
IEwRibbonControlX insertControlAt(int iIndex, EwRibbonControlType eRibbonControlType, BSTR strCommand, EwErrorCode *errorCode)
Insert a new control in Quick Access Toolbar.
VARIANT getQuickAccessControlIDArray(EwErrorCode *errorCode)
Call this member to get array of control IDs in Quick Access Toolbar.
int getControlCount(EwErrorCode *errorCode)
Return the number of controls in Quick Access Toolbar.
IEwRibbonControlX findControlByID(int iControlId, EwErrorCode *errorCode)
Call this member to find the specified control in Quick Access Toolbar.
EwErrorCode removeControlAt(int iIndex)
Remove a control specified by the index in Quick Access Toolbar.
IEwRibbonComboBoxControlX addComboBoxControl(EwErrorCode *errorCode)
Add the ComboBox Control in Quick Access Toolbar.
IEwRibbonControlX getControlAt(int iIndex, EwErrorCode *errorCode)
Return the specified control of Quick Access Toolbar.
EwErrorCode addToDefaultControls(int iControlID)
Add control to the list of default controls in Quick Access Toolbar.
IEwRibbonControlX addControl(EwRibbonControlType eRibbonControlType, BSTR strCommand, EwErrorCode *errorCode)
Add a new control at the end of Quick Access Toolbar.
IEwRibbonControlX addRibbonControl(int iControlID, EwRibbonControlType eType, BSTR strCommand, EwErrorCode *errorCode)
Add an existing ribbon control at the end of Quick Access Toolbar.
Use this interface to manage the Ribbon tabs.
Definition: EwApplicationRibbon.idl:858
EwErrorCode removeGroup(int iIndex)
Remove a group specified by the index.
IEwRibbonGroupX insertGroup(BSTR strCaption, int iIndex, EwErrorCode *errorCode)
Add a new group at the specified index of the ribbon tab.
BSTR getCaption(EwErrorCode *errorCode)
Return the caption of this tab.
EwErrorCode setCaption(BSTR strCaption)
Set a new caption for this tab.
int getGroupCount(EwErrorCode *errorCode)
Return the number of group in the current tab.
int getIndex(EwErrorCode *errorCode)
Return the index of the tab.
EwErrorCode setVisible(VARIANT_BOOL bVisible)
Hide or show the tab.
VARIANT_BOOL isEnabled(EwErrorCode *errorCode)
Determine if the tab is enabled.
VARIANT_BOOL isVisible(EwErrorCode *errorCode)
Determine if the tab is visible.
long getID(EwErrorCode *errorCode)
Get the Id's of Tab.
IEwRibbonGroupX getGroupAt(int iIndex, EwErrorCode *errorCode)
Return the specified group of the current tab.
IEwRibbonGroupX addGroup(BSTR strCaption, EwErrorCode *errorCode)
Add a new group at the end of the ribbon tab.
EwErrorCode removeAllGroup()
Remove all groups.
EwErrorCode setEnabled(VARIANT_BOOL bEnabled)
Set whether the tab is enabled.
Use this interface to manage the Ribbon Bar.
Definition: EwApplicationRibbon.idl:1245
int getTabCount(EwErrorCode *errorCode)
Return the number of tab of this ribbon bar.
IEwRibbonTabX getSelectedTab(EwErrorCode *errorCode)
Return an IEwRibbonTabX that encapsulate the selected Ribbon Tab.
IEwRibbonTabX addTab(BSTR strCaption, EwErrorCode *errorCode)
Return an IEwRibbonTabX added to the Ribbon Tab.
IEwRibbonTabX insertTab(BSTR strCaption, int iIndex, EwErrorCode *errorCode)
Insert new tab for ribbon bar to specified position and return the IEwRibbonTabX inserted.
IEwRibbonTabX findTabByEnum(EwRibbonMainTabType eRibbonMainTabType, EwErrorCode *errorCode)
Return an IEwRibbonTabX object find by the input EwRibbonMainTabType enumeration.
EwErrorCode removeTab(int iIndex)
Remove a Ribbon Tab specified by the index.
IEwRibbonTabX findTabByID(int iID, EwErrorCode *errorCode)
Return an IEwRibbonTabX object that has the ID passed as parameter.
EwErrorCode setSelectedTab(int iIndex)
Select a Ribbon Tab.
IEwRibbonQuickAccessControlX getQuickAccessControl(EwErrorCode *errorCode)
Return an IEwRibbonQuickAccessControlX object.
IEwRibbonTabX getTabAt(int iIndex, EwErrorCode *errorCode)
Return an IEwRibbonTabX that encapsulate the Ribbon Tab specified by index.


Provide feedback on this topic

SOLIDWORKS welcomes your feedback concerning the presentation, accuracy, and thoroughness of the documentation. Use the form below to send your comments and suggestions about this topic directly to our documentation team. The documentation team cannot answer technical support questions. Click here for information about technical support.

* Required

 
*Email:  
Subject:   Feedback on Help Topics
Page:   SOLIDWORKS Electrical API: idl_converted/EwApplicationRibbon.idl Source File
*Comment:  
*   I acknowledge I have read and I hereby accept the privacy policy under which my Personal Data will be used by Dassault Systèmes

Print Topic

Select the scope of content to print:

x

We have detected you are using a browser version older than Internet Explorer 7. For optimized display, we suggest upgrading your browser to Internet Explorer 7 or newer.

 Never show this message again
x

Web Help Content Version: API Help (English only) 2023 SP05

To disable Web help from within SOLIDWORKS and use local help instead, click Help > Use SOLIDWORKS Web Help.

To report problems encountered with the Web help interface and search, contact your local support representative. To provide feedback on individual help topics, use the “Feedback on this topic” link on the individual topic page.