• 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. Setting layout highlight colour/visibility

Stats

  • Locked Locked
  • Replies 5
  • Subscribers 143
  • Views 6039
  • 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

Setting layout highlight colour/visibility

NickA
NickA over 5 years ago

I'm writing a function that needs to set the highlight colour for leMarkNet. I am able to do so by copying what comes up in the log when changing the colour in the MarkNet options (sample below) and repeating it in my procedure. However, the hex number in red is different in every session. 

le0MarkNetForm->optionTabs->page1->markNetColor->value= list(ptrnum@0x58e7b180 112 26 "y2 (drawing)")

It seems that the red hex "ID" for y0/1/2/3/... are all separated by 0x10 (ie if y2 is 0x58e7b180, then y1 will be 0x58e7b170 and y0 will be 0x58e7b160), and I nearly got there by using this command...

le0MarkNetForm->optionTabs->page1->markNetColor->value

It reports this... 

(ptrnum@0x58e7b180 112 26 "y2 (drawing)")

...which I managed to use to calculate the value that y0's "ID" is, and am then am using that with an offset to try to set the colour. I can format it all back into a string (say "ptrnum@0x58e7b160"), as I don't know what data structure the "ptrnum@XXX" format is. I then tried to convert it to a symbol in the function, which may be the wrong approach...

le0MarkNetForm->optionTabs->page1->markNetColor->value= list(stringToSymbol(ptr) 112 26 "y0 (drawing)")

However, when I do this, it gives me this error... 

WARNING* Form 'le0MarkNetForm', scroll region 'page1', field 'markNetColor': Bad value (ptrnum\@0x58e7b160 112 26 "y0 (drawing)").
Cyclic value is not a valid icon or string-icon pair.
(ptrnum\@0x58e7b160 112 26 "y0 (drawing)")

Is there a better way to do this? 

Also, once I've highlighted some nets with leMarkNet, the y0/1/2/... layers still stay visible even if I set them as invisible in the layer palette. Is there a way to change this? My goal is to highlight a bunch of different groups of nets in different colours and then, ideally, to allow the groups to be turned on/off as needed to see different groups in any one view.

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

    I'm not sure why you need to do this. If using leMarkNet(), it has a ?markNetColor argument which allows you to specify the layer to use (y0 through y9). Perhaps you're using leHiMarkNet() instead though? If you really need to do that, then you could find the matching choice in the choices and use that (note, the FUNCTION in the code below should be a single word made up of "sub" and "string" concatenated, but due to a bug with the forum it doesn't let me post any message that includes it in as one word - a slightly bizarre bug I found a while ago):

    color=car(exists(choice le0MarkNetForm->optionTabs->page1->markNetColor->choices FUNCTION(cadddr(choice) 1 2)=="y2"))
    le0MarkNetForm->optionTabs->page1->markNetColor->value=color

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • NickA
    NickA over 5 years ago in reply to Andrew Beckett

    Very much appreciate the reply. 

    > I'm not sure why you need to do this. If using leMarkNet(), it has a ?markNetColor argument which allows you to specify the layer to use (y0 through y9).

    Yes! That's exactly what I'm after, but how do I specify this in the function call? I am currently using leMarkNet(pinCenter), where pinCenter is the centre-point of what I want to highlight. I just tried leMarkNet(?markNetColor"y0" pinCenter) and it doesn't like it. I'm guessing I'm doing something wrong, but don't know where to look for syntax on this function.

    Also, is there a reason why y0-9 stay visible in the layout even if they are marked as invisible in the layout pallet?

    Nick

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • NickA
    NickA over 5 years ago in reply to NickA

    Don't worry, I worked it out! Using this works... leMarkNet(pinCenter ?markNetColor "y0"). Thanks very much for your help :)

    I'd still be interested to understand if it's possible to turn off/on y0/1/2/... in the layer palette after highlight 

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 5 years ago in reply to NickA

    Hi Nick,

    Any required arguments (and the point is a required argument) have to be passed first, before optional keyword arguments. So you'd need:

    leMarkNet(pinCenter ?markNetColor "y4")

    You can find syntax by using cdsFinder and searching for leMarkNet, or in the menus in Virtuoso pick a Help menu and in the search box at the top, type leMarkNet.

    The layer palette controls display of actual drawn layer shapes, and these are implemented using "hilight" objects (not part of the database) and their visibility is not controlled via the layer palette.

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • Andrew Beckett
    Andrew Beckett over 5 years ago in reply to NickA

    Hi Nick,

    Any required arguments (and the point is a required argument) have to be passed first, before optional keyword arguments. So you'd need:

    leMarkNet(pinCenter ?markNetColor "y4")

    You can find syntax by using cdsFinder and searching for leMarkNet, or in the menus in Virtuoso pick a Help menu and in the search box at the top, type leMarkNet.

    The layer palette controls display of actual drawn layer shapes, and these are implemented using "hilight" objects (not part of the database) and their visibility is not controlled via the layer palette.

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Children
  • NickA
    NickA over 5 years ago in reply to Andrew Beckett

    Thankyou Andrew!

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel

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