Hide markers frames

Hi-

I noticed that on latest versions (i tried on 0.30.5), markers frames always show when adding a marker to LayoutView (0.28.5 does not do that).
Is there a way to turn off marker frames?
I also tried to set the frame color to be the same as the background color but it sets both the marker and the frame.

Thanks!

def addTextMarker(self,layoutView, x,y,string,color):
  m = pya.Marker(layoutView)
  bgColor = pya.QColor(layoutView.get_config("background-color"))
  m.color = color.red*65536 + color.green*256 + color.blue
  m.frame_color = bgColor.red*65536 + bgColor.green*256 + bgColor.blue      
  m.set_text(pya.DText(string,pya.DTrans(pya.DPoint(x,y))))   
  m.line_width = 10

Comments

  • Hi @mikamar,

    right now, there is no option to turn that off. The box was introduced when the labels became non-point objects. They indicate the "active" area of a text - i.e. the one where you select the text from. So it was important to show that in the marker, for example once you have selected it. The frame shares the color with the text. The frame replaces the single dot that was drawn at the origin of the text.

    To disable that I need to introduce a new configuration option for the marker. If you like, you can raise a ticket on GitHub for introducing that option. I will implement it for the next minor release then.

    Matthias

  • Thanks for your help here. One last low priority request on this topic: can the text frames be disabled by default?
    Let me know if ticket is needed.

    Thanks,

  • Well, configuration options are saved in the config file, so if I set a default, it's not going to be effective for people who already have used KLayout once.

    If you own a organization-wide installation, there are some ways you can tune the defaults yourself:

    1. Place a custom "klayoutrc" file next to the binary. KLayout will read these settings there to initialize the configuration
    2. Install a global script (e.g. in a folder called "macros" or "pymacros" next to the binary) that sets the configuration to some specified values. If you make this script autorun, it is called whenever KLayout is started. That allows resetting the configuration on a per-call basis.

    Such a scheme is used sometimes to establish more default settings such as background color, or to disable certain features a standard user should not see.

    Matthias

Sign In or Register to comment.