Class LayoutView (version 0.18)Description: The view object presenting one or more layout objects The visual part of the view is the tab panel in the main window. The non-visual part are the redraw thread, the layout handles, cell lists, layer view lists etc. This object controls these aspects of the view and controls the appearance of the data.
Method Overview
[const] int active_cellview_indexDescription: Get the index of the active cellview (shown in hierarchy browser)
add_cell_visibility_observer( ref ObserverBase observer )Description: Add a cell visibility observer If a cell is hidden or shown, this observer is triggered.
add_cellview_list_observer( ref ObserverBase observer )Description: Add a cellview list observer If a cellview is added or removed, this observer is triggered.
add_cellview_observer( ref ObserverBase observer )Description: Add a cellview observer If a cellview is changed (i.e. the cell is changed) this event is sent. The integer argument slot ("signal_int") of the observer will be triggered as well with the index of the cellview that has changed.
add_file_open_observer( ref ObserverBase observer )Description: Add a file open observer If a new file is loaded, this observer is triggered.
add_layer_list_observer( ref ObserverBase observer )Description: Add a layer list observer If the layer list changes, the observer's "signal_int" and "signal" slot is triggered. The int's bit 0 is set, if the properties have changed. If the arguments bit 1 is set, the hierarchy has changed.
add_selection_changed_observer( ref ObserverBase observer )Description: Add a selection observer If the selection is changed, this observer is triggered. This method was added in version 0.18.
unsigned int add_stipple( string name, unsigned int data[ ], unsigned int bits )Description: Add a stipple pattern 'data' is an array of unsigned integers describing the bits that make up the stipple pattern. If the array has less than 32 entries, the pattern will be repeated vertically. The number of bits used can be less than 32 bit which can be specified by the 'bits' parameter. Logically, the pattern will be put at the end of the list.
add_transient_selection_changed_observer( ref ObserverBase observer )Description: Add a transient selection observer If the transient selection is changed, this observer is triggered. This method was added in version 0.18.
add_viewport_changed_observer( ref ObserverBase observer )Description: Add a viewport changed observer If the viewport (the rectangle that is shown) changes, this observer is triggered.
InstElement ascend( int index )Description: Ascend upwards in the hierarchy. Removes one element from the specific path of the cellview with the given index. Returns the element removed.
[const] LayerPropertiesIterator begin_layersDescription: Begin iterator for the layers This iterator delivers the layers of this view, either in a recursive or non-recursive fashion, depending which iterator increment methods are used. The iterator delivered by end_layers is the past-the-end iterator. It can be compared agains a current iterator to check, if there are no further elements.
bookmark_view( string name )Description: Bookmark the current view under the given name
[const] DBox boxDescription: Return the displayed box in micron space
cancelDescription: Cancel all edit operations
[const] const ref CellView cellview( unsigned int cv_index )Description: Get the cellview object for a given index
[const] unsigned int cellviewsDescription: Get the number of cellviews
clear_annotationsDescription: Clear all annotations on this view
clear_configDescription: Clear the local configuration parameters See set_config for a description of the local configuration parameters.
clear_layersDescription: Clear all layers
clear_stipplesDescription: Remove all stipple pattern All stipple pattern except the fixed ones are removed. If any of the custom stipple pattern is still used by the layers displayed, the results will not be predictable.
clear_transactionsDescription: Clear all transactions Discard all actions in the undo buffer. After clearing that buffer, no undo is available. It is important to clear the buffer when making database modifications outside transactions, i.e after that modifications have been done. If failing to do so, 'undo' operations are likely to produce invalid results. This method was introduced in version 0.16.
commitDescription: End a transaction See transaction for a detailed description of transactions. This method was introduced in version 0.16.
unsigned int create_layout( bool add_cellview )Description: Create a new, empty layout The add_cellview parameter controls whether to create a new cellview (true) or clear all cellviews before.
[const] LayerPropertiesIterator current_layerDescription: Get the current layer view Returns the LayerPropertiesIterator pointing to the current layer view (the one that has the focus). If no layer view is active currently, a null iterator is returned.
delete_layer( ref LayerPropertiesIterator iter )Description: Delete the layer properties node This method deletes the object that the iterator points to and invalidates the iterator since the object that the iterator points to is no longer valid.
descend( InstElement path[ ], int index )Description: Descend further into the hierarchy. Adds the given path (given as an array of InstElement objects) to the specific path of the cellview with the given index. In effect, the cell addressed by the terminal of the new path components can be shown in the context of the upper cells, if the minimum hierarchy level is set to a negative value. The path is assumed to originate from the current cell and contain specific instances sorted from top to bottom.
destroyDescription: Explicitly destroy the object Explicitly destroy the object on C++ side if it was owned by the Ruby interpreter. Subsequent access to this object will throw an exception. If the object is not owned by Ruby, this method will do nothing.
[const] bool destroyedDescription: Tell, if the object was destroyed This method returns true, if the object was destroyed, either explicitly or by the C++ side. The latter may happen, if the object is owned by a C++ object which got destroyed itself.
yield const ref Annotation each_annotationDescription: Iterate over all annotations attached to this view
[const] yield const ref ObjectInstPath each_object_selectedDescription: Iterate over each selected geometrical object, yielding a ObjectInstPath object for each of them
[const] yield const ref ObjectInstPath each_object_selected_transientDescription: Iterate over each geometrical objects in the transient selection, yielding a ObjectInstPath object for each of them This method was introduced in version 0.18.
enable_edits( bool enable )Description: Enable or disable editing
[const] LayerPropertiesIterator end_layersDescription: End iterator for the layers See begin_layers for a description about this iterator
erase_cellview( unsigned int index )Description: Erase the cellview with the given index This closes the given cellview and unloads the layout associated with it, unless referred to by another cellview.
[const] string get_config( string name )Description: Query a local configuration parameter See set_config for a description of the local configuration parameters.
[const] unsigned int[ ] get_current_cell_path( int cv_index )Description: Cell path of the current cell The current cell is the one highlighted in the browser with the focus rectangle. The current path is returned for the cellview given by cv_index. The cell path is a list of cell indices from the top cell to the current cell.
[const] bool has_object_selection?Description: Returns true, if geometrical objects (shapes or cell instances) are selected in this view
[const] bool has_transient_object_selection?Description: Returns true, if geometrical objects (shapes or cell instances) are selected in this view in the transient selection The transient selection represents the objects selected when the mouse hovers over the layout windows. This selection is not used for operations but rather to indicate which object would be selected if the mouse is clicked. This method was introduced in version 0.18.
hide_cell( unsigned int cell_index, int cv_index )Description: Hide the given cell for the given cellview
insert_annotation( Annotation obj )Description: Insert an annotation object into the given view Insert the annotation object given by obj into the view.
const ref LayerPropertiesNode insert_layer( LayerPropertiesIterator iter, LayerPropertiesNode node )Description: Insert the given layer properties node into the list before the given position This method inserts the new properties node before the position given by "iter" and returns a const reference to the element created.
[const] bool is_cell_hidden( unsigned int cell_index, int cv_index )Description: Tell, if the cell is hidden
load_layer_props( string fn )Description: Load the layer properties Load the layer properties from the file given in "fn"
unsigned int load_layout( string filename, LoadLayoutOptions options, bool add_cellview )Description: Load a (new) file into the layout view Loads the file given by the "filename" parameter. The options specify various options for reading the file. The add_cellview param controls whether to create a new cellview (true) or clear all cellviews before (false). This method has been introduced in version 0.18.
unsigned int load_layout( string filename, bool add_cellview )Description: Load a (new) file into the layout view Loads the file given by the "filename" parameter. The add_cellview param controls whether to create a new cellview (true) or clear all cellviews before (false).
max_hierDescription: Select all hierarchy levels available Show the layout in full depth down to the deepest level of hierarchy. This method may cause a redraw.
max_hier_levels=( int level )Description: Set the maximum hierarchy level up to which to display geometries This methods allows to set the maximum hierarchy below which to display geometries.This method may cause a redraw if required.
[const] int max_hier_levels?Description: Query the maximum hierarchy level up to which to display geometries
min_hier_levels=( int level )Description: Set the minimum hierarchy level at which to display geometries This methods allows to set the minimum hierarchy level above which to display geometries.This method may cause a redraw if required.
[const] int min_hier_levels?Description: Query the minimum hierarchy level at which to display geometries
pan_center( DPoint p )Description: Pan to the given point The window is positioned such that "p" becomes the new center
pan_downDescription: Pan down
pan_leftDescription: Pan to the left
pan_rightDescription: Pan to the right
pan_upDescription: Pan upward
reload_layout( unsigned int cv )Description: Reload the given cellview
remove_cell_visibility_observer( ref ObserverBase observer )Description: Remove a cell visibility observer
remove_cellview_list_observer( ref ObserverBase observer )Description: Remove a cellview list observer
remove_cellview_observer( ref ObserverBase observer )Description: Remove a cellview observer
remove_file_open_observer( ref ObserverBase observer )Description: Remove a file open observer
remove_layer_list_observer( ref ObserverBase observer )Description: Remove a layer list observer
remove_selection_changed_observer( ref ObserverBase observer )Description: Remove a selection observer This method was added in version 0.18.
remove_stipple( unsigned int index )Description: Remove the stipple pattern with the given index The pattern with an index less than 16 cannot be removed. If a stipple pattern is removed that is still used, the results are not predictable.
remove_transient_selection_changed_observer( ref ObserverBase observer )Description: Remove a transient selection observer This method was added in version 0.18.
remove_viewport_changed_observer( ref ObserverBase observer )Description: Remove a viewport changed observer
rename_cellview( string name, int index )Description: Rename the cellview with the given index If the name is not unique, a unique name will be constructed from the name given. The name may be different from the filename but is associated with the layout object. If a layout is shared between multiple cellviews (which may happen due to a clone of the layout view for example), both cellviews are renamed.
replace_layer_node( LayerPropertiesIterator iter, LayerPropertiesNode node )Description: Replace the layer node at the position given by "iter" with a new one
reset_titleDescription: Reset the title to the standard title See set_title and title for a description about how titles are handled.
save_as( unsigned int index, string filename, bool gzip, SaveLayoutOptions options )Description: Save a layout to the given stream file The given layout (with the given index) is written to the stream file with the given options. 'options' is a SaveLayoutOptions object that specifies which format to write and further options such as scaling factor etc. Calling this method is equivalent to calling 'write' on the respective layout object.
save_image( string filename, unsigned int width, unsigned int height )Description: Save the layout as an image to the given file The image contains the current scene (layout, annotations etc.). The image is written as a PNG file to the given file. The image is drawn synchroneously with the given width and height. Drawing may take some time.
save_layer_props( string fn )Description: Save the layer properties Save the layer properties to the file given in "fn"
save_screenshot( string filename )Description: Save a screenshot to the given file The screenshot is written as a PNG file to the given file. This requires the drawing to be complete. Ideally, synchroneous mode is switched on for the application to guarantee this condition. The image will have the size of the viewport showing the current layout.
select_cell( unsigned int cell_index, int cv_index )Description: Select a cell by index for a certain cell view Select the current (top) cell by specifying a path (a list of cell indices from top to the actual cell) and the cellview index for which this cell should become the currently shown one. This method selects the cell to be drawn. In constrast, the set_current_cell_path method selects the cell that is highlighted in the cell tree (but not necessarily drawn).
select_cell_path( unsigned int cell_index[ ], int cv_index )Description: Select a cell by cell index for a certain cell view Select the current (top) cell by specifying a cell indexand the cellview index for which this cell should become the currently shown one. The path to the cell is constructed by selecting one that leads to a top cell. This method selects the cell to be drawn. In constrast, the set_current_cell_path method selects the cell that is highlighted in the cell tree (but not necessarily drawn).
[const] LayerPropertiesIterator[ ] selected_layersDescription: Get the selected layers Returns an array of LayerPropertiesIterator objects pointing to the currently selected layers. If no layer view is selected currently, an empty array is returned.
set_active_cellview_index( int index )Description: Make the cellview with the given index the active one (shown in hierarchy browser)
set_config( string name, string value )Description: Set a local configuration parameter with the given name to the given value This method sets a local configuration parameter with the given name to the given value. Values can only be strings. Numerical values have to be converted into strings first. Local configuration parameters override global configurations for this specific view. This allows for example to override global settings of background colors. Any local settings are not written to the configuration file.
set_current_cell_path( int cv_index, unsigned int[ ] )Description: Set the path to the current cell The current cell is the one highlighted in the browser with the focus rectangle. The cell given by the path is hightlighted and scrolled into view. To select the cell to be drawn, use the select_cell or select_cell_path method.
set_layer_properties( LayerPropertiesIterator iter, LayerProperties props )Description: Set the layer properties of the layer pointed to by the iterator This method replaces the layer properties of the element pointed to by "iter" by the properties given by "props". It will not change the hierarchy but just the properties of the given node.
set_title( string title )Description: Set the title of the view Override the standard title of the view indicating the file names loaded by the specified title string. The title string can be reset with reset_title to the standard title again.
show_all_cellsDescription: Make all cells shown (cancel effects of hide_cell)
show_cell( unsigned int cell_index, int cv_index )Description: Show the given cell for the given cellview (cancel effect of hide_cell)
stopDescription: Stop redraw thread and close any browsers This method usually does not need to be called explicitly. The redraw thread is stopped automatically.
stop_redrawDescription: Stop the redraw thread It is very important to stop the redraw thread before applying changes to the layout or the cell views and the LayoutView configuration. This is usually done automatically. For rare cases, where this is not the case, this method is provided.
[const] string titleDescription: Return the view's title string The title string is either a string composed of the file names loaded (in some "readable" manner) or a customized title string set by set_title.
bool transactingDescription: Tell if a transaction is ongoing See transaction for a detailed description of transactions. This method was introduced in version 0.16.
transaction( string description )Description: Begin a transaction A transaction brackets a sequence of database modifications that appear as a single undo action. Only modifications that are wrapped inside a transaction..commit call pair can be undone. Each transaction must be terminated with a commit method call, even if some error occured. It is advisable therefore to catch errors and issue a commit call in this case. This method was introduced in version 0.16.
update_contentDescription: Update the layout view to the current state This method triggers an update of the hierarchy tree and layer view tree. Usually, this method does not need to be called. The widgets are updated automatically in most cases. Currently, this method MUST be called however, after the layer view tree has been changed by the insert_layer, replace_layer_node or delete_layer methods.
[const] int viewport_heightDescription: Return the viewport height in pixels This method was introduced in version 0.18.
[const] DCplxTrans viewport_transDescription: Return the transformation that converts micron coordinates to pixels Hint: the transformation returned will convert any point in micron coordinate space into a pixel coordinate. Contrary to usual convention, the y pixel coordinate is given in a mathematically oriented space - which means the bottom coordinate is 0. This method was introduced in version 0.18.
[const] int viewport_widthDescription: Return the viewport width in pixels This method was introduced in version 0.18.
zoom_box( DBox box )Description: Set the viewport to the given box
zoom_fitDescription: Fit the contents of the current view into the window
zoom_inDescription: Zoom in somewhat
zoom_outDescription: Zoom out somewhat
|