Hi EugeneZelenko
Add a process_events before get_image should able to solved this issue
current_view.update_content() pya.Application.instance().process_events() current_view.get_image(800, 600).save(f'Screenshot.{index}.png')
Hi MooGyuBae
I think this is highly dependes on the complexity of your work and the size of your layout project.
Previously I do most of my layout related stuff on a old gen intel i3 2C4T CPU, 4G ram, Win32 platform. which occasionally runs into a…
Hi Aadoo,
If the intension is to create a ring, the simplest way is to provide a polygon to the region.
which skips the steps of to messing arond with pcell variables
mainWindow = RBA::Application::instance::main_windowlayout = mainWindow::cur…
Hi Aadoo,
circ1.flatten provide void return to reg1, which causes the interpreter to complaint.
region only can be initiallized with shape like object, which also cannot take a cell or flattened cell as input.
to make the machine happy, you need …
Hi CMeyer
As tomas2004 mensioned, each file needs to have a unique LIB name, otherwise KLayout will only show one component.
The LIB name can be modified through save file dialog.
(Image)
Hi jiunnweiyeh,
for demostration purpose, previous examples includeds several layers that is not neccessary, here's an condensed version without generating those layers.
$mainWindow = RBA::Application::instance::main_window$layoutView = $mainWindo…
Hi Nacer,
a similar disscussion about center measurement, for your reference.
https://www.klayout.de/forum/discussion/894/slice-a-shape-into-two-parts#latest
Or, simply install the center ruler plugin from the package.
Hi jiunnweiyeh
I found this is very difficult to be achieve by DRC function,
Here's an example of filtering out rule violated edges, shift them and stitch them back to from a shape using Ruby API.
(Image)
(Image)
$mainWindow = RBA::Applic…
Hi nmz787_intel,
if your intension is to measure from shape center (boundbox center) without modify the layout
then you'll need to use Plugin to create custom ruler like example below.
It kind of work under my limited test cases.
1. selected ONE …
Hi vanwal,
You can right click on cell list and select flat cell list
then select every cell and hide them
another method is to use macro, this binds a Hide All cells short cut in tools menu if you enable this to be run at start up.
import pyamai…
Hi nmz787_intel,
(Image)
Here's an example of split selected shapes in half,
you can paste this into py macro page and enable "run on startup "
then it'll be bounded to the tool menu.
Due to the nature of gds, shapes might have remain…
HI tomas2004,
This should be the code you are looking for, however this seems like not implemented by Py/Ruby API.
https://github.com/KLayout/klayout/blob/a29bef496af81f1afc1bf3a08ad9fb2eb89890e6/src/lib/lib/libBasicText.cc#L48
If you want to crea…
Hi dick_freebird
In my case, copy and pasting object indeed changes the view,
but it only pan/zoom fit to the object, it won't make it as a new top.
The auto zoom/pan can be disabled through this setting.
(Image)
Hi eherrm,
The dbu can be modified thuough setting attribute of a Layout object
ly = RBA::Layout::new()ly.dbu = opt.dbu #add this to modify dbu
https://www.klayout.de/doc-qt5/code/class_Layout.html#method54
Hi ManzAutomations
Tile processer can take multiple layers as parameters through input and output,
and the operation for those layers is defined during tp.queue is being called.
short example
tp = pya.TilingProcessor()tp.input("in_0"…
Hi Peter123,
To show specific layer(s) only, you'll need to adjust the visibility before taking the screen shots,
can tried to modify the code like this:
showLayer = [(0, 0)] #[(0, 0), (1, 1), (2, 2) ....] can have multiplefor index in layout.e…
Hi Peter123,
I tested the code abovein headless modes using two different approachs,
and both case can successfully produce Box1.png & Box2.png (W11x64)
Is there any further info about this case, currently I cannot reproduce the issue.
Here'…
HI TTR572
Assuming your are trying to save a QImage data into a image file, you can simply use the save function.
#image is QImageimage.save("file_path/file_name.png")
If you like to show the image in you widget, you can use QLabel widg…
Hi Peter123
some difference might reqiures a front end GUI to explan, following examples from left to right shows the difference
of using different view and add_cellview parameters.
1) show layout in headless layout view, the operation is done in…
Hi Peter123,
Regarding to this part, "view = pya.LayoutView()" creates a new layout view in background, not showing on the screen, which all the operation is going to take place, and that's why you'll not see a difference in UI.
show_la…
Hi werk,
Here's some gds cell naming recommendations
https://pubs.opengroup.org/onlinepubs/9629499/apdxa.htm
https://www.artwork.com/gdsii/qis/faq/qis_limits.htm
As a matter of curiosity, I've also tried to name cells with Emoji in KLayout…
Hi ManzAutomations
As to why the tabs is not showing correctly, this is due to the widget or tab is not set to bind with a parent widget.
System will automatically remove the unbinded widget to free up memory and results in tabs missing.
for insta…
Hi ManzAutomations
I slightly change the UI part of you code into a widget to hold dynamyc data.
(Image)
The example is as below, the parameter input part is generated randomly to simulate a dynamic data set.
from datetime import datetimeimport…
Hi Nacer,
The text polygon existed in a pCell, and the pCell is placed inside your current cell.
which means to see this shape you need to increase the viewing hierarchy level to at least 2.
The way to adjust the level is as below, both (A) or (B) …
Hi chgli
I think both case provides correct contours, however if the shape is generated by Pcell and using Region, KLayout will not turn the objects in Region into simple polygon right away (without cutline).
If you turn the pcell into static, sav…
Hi dick_freebird,
I do encounter application crash some time, but mostly the error is caused by my macro, rarely caused by basic editing.
If Klayout experience force quit caused crash, the setting you apply during the session including the "o…
Hi ManzAutomations,
here's an example of tab that holds random amound of data dynamically
The concept is to create a page widget that can be used repeatly, so later we can feed parameters into page and add to tab widget using loops.
(Image)
imp…
Hi Nacer
text can be added using pre-defined PCell in "basic" library
follow the step you can drop a instance of PCell in "Instance" panel
(Image)
You can config a pcell text and size from "Pcell" tab while you drop-…