• Skip to main content
  • Skip to search
  • Skip to footer
Cadence Home
  • This search text may be transcribed, used, stored, or accessed by our third-party service providers per our Cookie Policy and Privacy Policy.

  1. Community Forums
  2. Custom IC SKILL
  3. create icon in menu in IC6

Stats

  • Locked Locked
  • Replies 3
  • Subscribers 142
  • Views 14757
  • Members are here 0
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

create icon in menu in IC6

Aritra
Aritra over 12 years ago

Hi,

 I am tring to create an icon for menu in IC6. Problem is, when I import the png file the icon comes as too small. The icon I have is of 361 X 233 pixels. I am using hiLoadIconFile( "<filePath>.PNG" 48 8 ). But the size seems to have no change with respect to width & hight.

 I read that hiLoadIconFile does not support any size of icons, only 16 X 16 pixels.

 Is there some other trick to include a bigger logo in menu?

Also please let me know can the position of the menu be changed (eg: beginning, between File & Edit etc..) ?

Please help. 

 

  • Cancel
Parents
  • Andrew Beckett
    Andrew Beckett over 12 years ago

    I was incorrect - some user interface functions which allow arguments allow the ?itemIcon to be specified as a file name (I've used them for buttons or toolbars for example), but if I do:

    item=hiCreateMenuItem(?name 'cadence ?itemText "Cadence" ?itemIcon "/tmp/cadence_logo.png" ?callback "println(\"Cadence\")")
    hiCreatePulldownMenu('testMenu "Test" list(item))
    hiInsertBannerMenu(hiGetCIWindow() testMenu 10)
    *Error* length: argument must be a list or an array - "/tmp/cadence_logo.png"

    Reading the documentation for ?itemIcon for hiCreateMenuItem it says:

    List representing an icon menu item. The icon occupies the icon area on the left of the menu item, and the text (specified in t_menuItemText) is displayed alongside. Menu icons can only be 16x16 pixels in size. If the icon is larger than 16x16 pixels, it will be shrunk (which is why only 16x16 icons are recommended for the menu items). See Specifying Icons for hi Functions in Chapter 7 for information about how to specify an icon as an argument.

    So you are limited to 16x16 icons for menu items.

    Regards,

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • Andrew Beckett
    Andrew Beckett over 12 years ago

    I was incorrect - some user interface functions which allow arguments allow the ?itemIcon to be specified as a file name (I've used them for buttons or toolbars for example), but if I do:

    item=hiCreateMenuItem(?name 'cadence ?itemText "Cadence" ?itemIcon "/tmp/cadence_logo.png" ?callback "println(\"Cadence\")")
    hiCreatePulldownMenu('testMenu "Test" list(item))
    hiInsertBannerMenu(hiGetCIWindow() testMenu 10)
    *Error* length: argument must be a list or an array - "/tmp/cadence_logo.png"

    Reading the documentation for ?itemIcon for hiCreateMenuItem it says:

    List representing an icon menu item. The icon occupies the icon area on the left of the menu item, and the text (specified in t_menuItemText) is displayed alongside. Menu icons can only be 16x16 pixels in size. If the icon is larger than 16x16 pixels, it will be shrunk (which is why only 16x16 icons are recommended for the menu items). See Specifying Icons for hi Functions in Chapter 7 for information about how to specify an icon as an argument.

    So you are limited to 16x16 icons for menu items.

    Regards,

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Children
No Data

Community Guidelines

The Cadence Design Communities support Cadence users and technologists interacting to exchange ideas, news, technical information, and best practices to solve problems and get the most from Cadence technology. The community is open to everyone, and to provide the most value, we require participants to follow our Community Guidelines that facilitate a quality exchange of ideas and information. By accessing, contributing, using or downloading any materials from the site, you agree to be bound by the full Community Guidelines.

© 2025 Cadence Design Systems, Inc. All Rights Reserved.

  • Terms of Use
  • Privacy
  • Cookie Policy
  • US Trademarks
  • Do Not Sell or Share My Personal Information