Format Util
Class full path: Utils.FormatUtil.FormatUtil
Implementation of the format utilities
Functions
get_layer_pen_stroke_color(layer)
staticmethod
get the pen, stroke and color from the layer
Parameters:
Name | Type | Description | Default |
---|---|---|---|
layer
|
int | str
|
number of the layer |
required |
Returns:
Type | Description |
---|---|
tuple[bool, int, int, int]
|
tuple(pen, stroke, color) |
init_by_global_properties(build_ele)
staticmethod
initialize the values by global properties
Parameters:
Name | Type | Description | Default |
---|---|---|---|
build_ele
|
BuildingElement
|
building element with the parameter properties |
required |
init_list_by_global_properties(build_ele)
staticmethod
initialize the values by global properties
Parameters:
Name | Type | Description | Default |
---|---|---|---|
build_ele
|
BuildingElement
|
building element with the parameter properties |
required |
update_by_layer(color, color_by_layer, pen, pen_by_layer, stroke, stroke_by_layer, layer)
staticmethod
Update the common properties by layer
Parameters:
Name | Type | Description | Default |
---|---|---|---|
color
|
int
|
color |
required |
color_by_layer
|
bool
|
color by layer state |
required |
pen
|
int
|
pen |
required |
pen_by_layer
|
bool
|
pen by layer state |
required |
stroke
|
int
|
stroke |
required |
stroke_by_layer
|
bool
|
stroke by layer state |
required |
layer
|
int
|
layer |
required |
Returns:
Type | Description |
---|---|
tuple[int, int, int]
|
color, pen, stroke |