It looks like you're new here. If you want to get involved, click one of these buttons!
I found this thread, and this thread, about capturing a mouse click and its location, and about objects selection, and I was wondering if it is possible to create a procedure, where instead of a plugin, to have a procedure with a similar waiting mode for user to select an object.
Basically I want to make a procedure where it will enable a waiting mode for user to select a pcell instance and pop up a message box with its information.
I've build a procedure's template that pop ups info of already selected instances:
def getPCellInstInfo() : #pya.LayoutView().current().clear_object_selection() # waiting mode... # create check mechanism so the selected objects are only 1 sel_obj = pya.LayoutView().current().object_selection # remove for-loop - unnecessary for 1 inst for sel in sel_obj : lib = sel.inst().cell.pcell_library().name() name = sel.inst().cell.name #params = sel.inst().pcell_parameters_by_name() pya.MessageBox().info("PCell Info", "PCell Lib : " + str(lib) + "\nPCell Name : " + str(name), pya.MessageBox.Ok) # for # getPCellInstInfo
Thanks in advance,