Possible to access Basic library from standalone python module?

Hello,
I would like to access some of the functionality of the Basic library (specifically, the text generation) from within the standalone python module.
Inside the application the following code should work

import klayout.db as pya

lay = pya.Layout()
top = lay.create_cell("TOP")

para = {"text":  "Hello world", "mag": 1000, "layer": lay.layer(1, 0)}
pcell = lay.create_cell("TEXT", "Basic", para)
trans = pya.DCplxTrans.new(1, 0, False, 0, 0)
mycell = top.insert(pya.DCellInstArray.new(pcell.cell_index(), trans))

However, when used from the standalone module, it does not. The basic library does not seem to be exposed typically, (pya.Library.library_names() returns the empty list []), but I could also not find how I would load it.

Is there a way for me to load the Basic library from inside my standalone code?

Thanks a lot,

Clemens

Comments

Sign In or Register to comment.