Converter
content_extent(elements, min_width, min_height)
Return the (width, height) a layout-less container needs to cover its child widgets.
Without an explicit geometry, Qt calls adjustSize() on such a container when it is first shown and sizes it to the children visible at that moment, so a widget hidden at startup by a Visible rule (EDM visPv) is clipped when it later appears. The extent is at least min_width x min_height and reaches the furthest child's right/bottom edge, so widgets placed past the screen's declared size stay reachable.
Parameters
elements : Iterable[ET.Element]
Serialized child
Returns
tuple[int, int] The (width, height) covering the minimum size and every child's geometry. A child whose geometry rect is missing, incomplete or non-numeric is ignored.
Source code in pydmconverter/edm/converter.py
185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 | |
convert(input_path, output_path, scrollable=False, site=None, calc_list_file=None, color_list_file=None, search_paths=None, display_roots=None)
Convert an EDM .edl file to a PyDM .ui (plus a .py when it has menu muxes).
search_paths are extra directories searched, after the file's own directory
and before EDMDATAFILES, for symbol files, calc.list and the displays its links
open.
display_roots are absolute directories whose display names become root-relative
(see :mod:pydmconverter.edm.display_roots); PYDMCONVERTER_DISPLAY_ROOTS when
omitted.
Source code in pydmconverter/edm/converter.py
60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 | |