Module Simantics/DrawingTemplate

This module is undocumented. This is a list of its definitions.

assignTemplateToDiagram :: Resource -> Resource -> <WriteGraph> ()

Assigns the given Drawing Template to a single Diagram. Same as assignTemplateToDiagrams with a one element list.

assignTemplateToDiagrams :: [Resource] -> Resource -> <WriteGraph> ()

Assigns the given Drawing Template to the given Diagram instance

bindFlagToTable :: Resource -> Resource -> Double -> Double -> <WriteGraph> Boolean

bindFlagToTable diagram flag x y binds a flag to the IO table row of the diagram's drawing template that covers the position (x, y) on the diagram.

If no row covers the position, a flag that was bound has its binding cleared and is moved to (x, y) instead. Returns True when either of these happened and False when the flag was unbound and stays where it is.

createDrawingTemplate :: Resource -> <WriteGraph> Resource

Creates new Drawing Template under the given Drawing Template library instance. Returns the created Drawing Template.

createFilter :: Resource -> <WriteGraph> Resource

Creates new Filter under the given Flag Table instance. Returns the created Filter.

createFlagTable :: Resource -> <WriteGraph> Resource

Creates new Flag Table under the given Drawing Template instance. Returns the created Flag Table.

createFlagTypeVisual :: Resource -> <WriteGraph> Resource

Creates new FlagTypeVisual under the given Flag Table instance. Returns the created FlagTypeVisual

createImageInComposite :: Resource -> <WriteGraph> Resource

Creates new SVG image under the given Visual Composite instance. Returns the created SVG Image.

createImageInTable :: Resource -> <WriteGraph> Resource

Creates new SVG image under the given Flag Table instance. Returns the created SVG Image.

createLibraryInTemplate :: Resource -> <Proc> Resource

Creates a new Library under the given Drawing Template parameter. Returns the created Library.

createMonitor :: Resource -> <WriteGraph> Resource

Creates new Monitor under the given Flag Table instance. Returns the created Monitor.

createMonitorInComposite :: Resource -> <WriteGraph> Resource

Creates new Monitor under the given Visual Composite instance. Returns the created Monitor.

createVisualComposite :: Resource -> <WriteGraph> Resource

Creates new Visual Composite under the given Drawing Template instance. Returns the created Visual Composite.

drawingTemplateLibraryOf :: Resource -> <ReadGraph> Resource

Returns the Drawing Template library folder of the given Model instance.

exportDrawingTemplate :: File -> Resource -> <Proc> ()

Exports the given Drawing Template to the given File location

importDrawingTemplate :: Resource -> File -> <Proc> Resource

importDrawingTemplate model file imports a drawing template exported by exportDrawingTemplate into the Drawing Template library of the model, creating that library if the model does not have one yet. A template already in the library under the file's base name is removed first, so importing replaces rather than duplicates. Returns the imported root.

A failed import is only logged, not raised, and the result is then a Java null that fails when it is used.

setFlagTablePropertyValue :: Resource -> String -> String -> <WriteGraph> ()

setFlagTablePropertyValue flagTable property newValue writes the display value of one property of a flag table, the value being given in the display form the user would type.

setMonitorPropertyValue :: Resource -> String -> String -> <WriteGraph> ()

setMonitorPropertyValue monitor property newValue writes the display value of one property of a template monitor, the value being given in the display form the user would type.

templateComposite :: Variable -> <ReadGraph> Variable

The composite that corresponds to the diagram the drawing template is currently drawn on. self is the template scenegraph node the expression belongs to. Fails if the node has no runtime variable.

templateDiagram :: Variable -> <ReadGraph> Variable

The diagram the drawing template is currently drawn on. self is the template scenegraph node the expression belongs to. Fails if the node has no runtime variable.

templateModel :: Variable -> <ReadGraph> Variable

The model containing the diagram the drawing template is currently drawn on. self is the template scenegraph node the expression belongs to. Fails if the node has no runtime variable.