The Global ARCHICAD Community

Stay informed. Get help. Share your knowledge.

Discussions about using GRAPHISOFT's tools (API DevKit) for independent software developers

Moderators: Karl Ottenstein, LaszloNagy, ejrolon, Barry Kelly, gkmethy, rmasaki, MOREH Tamas, Akos Somorjai, Ed Brown, Mihály Palenik, Tibor Lorántfy

User avatar
By Tsepov
I try to assign to menu item "Show/close" the icon "Panel_icon".
Create icon with ID 30650
Place ID 32650 to menu text as ^32650.
But no icon pictures show in my menu (((.
in RegisterInterface (void):

err = ACAPI_Register_Menu (32503, 0, MenuCode_Extras, MenuFlag_Default);
in file .grc:

'STR#' 32503 "Solaris menu" {
/* [ ] */ "LabPP - Squares"
/* [ ] */ "Show/close^E3^ES^EE^EI^ED^EL^EW^ET^32650"
in file ...fix.grc:

'GICN' 32650 "Settings Extra page icon" {
0 128 128
Just to make it clear:
If you register a menu item using ACAPI_Register_Menu, then you must create an 'STR#' resource for the text of the menu items into your localized GRC file.
You can set extra flags for a menu items using the '^' character.
For example "^E3^ES^32650" means that this menu will be enabled also when a 3D or Section window is active (by default Add-Ons' menu items are enabled only when the 2D floor plan window is active) and the icon with 32650 identifier will be added to the menu item.
The 32650 icon identifier refers to a 'GICN' icon resource defined in your GRC file.

See all available flags inside the documentation: ... -resources

Note that from ARCHICAD 20 'GICN' icon resources can be attached to menu items (previously you had to use 'GBMP'). The possible source image formats of 'GICN' icon resources are PNG and SVG (previously you had to use BMP).