From 7e9d0e27073537f6e5f91cd1755ac7b8b12da339 Mon Sep 17 00:00:00 2001 From: Michael Brunner Date: Wed, 2 Oct 2024 09:42:42 +0200 Subject: [PATCH 1/3] - add new cwapi3d functions for build >= 30.0.593 --- docs/documentation/bim_team_upload_result.md | 6 + docs/documentation/enums.md | 7 + docs/release_notes.md | 75 ++++++++++ mkdocs.yml | 1 + src/cadwork/bim_team_upload_result.pyi | 17 +++ src/cadwork/bim_team_upload_result_code.pyi | 26 ++++ src/element_controller/__init__.pyi | 11 ++ src/file_controller/__init__.pyi | 93 ++++++++++++- src/utility_controller/__init__.pyi | 139 +++++++++++++++++++ 9 files changed, 370 insertions(+), 5 deletions(-) create mode 100644 docs/documentation/bim_team_upload_result.md create mode 100644 src/cadwork/bim_team_upload_result.pyi create mode 100644 src/cadwork/bim_team_upload_result_code.pyi diff --git a/docs/documentation/bim_team_upload_result.md b/docs/documentation/bim_team_upload_result.md new file mode 100644 index 0000000..9480cff --- /dev/null +++ b/docs/documentation/bim_team_upload_result.md @@ -0,0 +1,6 @@ +# BIMteam upload + +::: src.cadwork.bim_team_upload_result + rendering: + show_root_heading: false + show_source: true \ No newline at end of file diff --git a/docs/documentation/enums.md b/docs/documentation/enums.md index 225f593..f760e3a 100644 --- a/docs/documentation/enums.md +++ b/docs/documentation/enums.md @@ -66,3 +66,10 @@ rendering: show_root_heading: false show_source: true + +## BIMteam upload + +::: src.cadwork.bim_team_upload_result_code + rendering: + show_root_heading: false + show_source: true diff --git a/docs/release_notes.md b/docs/release_notes.md index b3eaa13..b3e5697 100644 --- a/docs/release_notes.md +++ b/docs/release_notes.md @@ -54,6 +54,80 @@ def set_element_group_multi_select_mode() ->None: ``` +#### get_elements_in_collision + +```python +def get_elements_in_collision(element: int) ->List[int]: + """get elements in collision + + Parameters: + element: element + + Returns: + List[int] + """ + +``` + +## New Items +### Functions file_controller +#### export_step_file_cut_drillings + +```python +def export_step_file_cut_drillings(elements: List[int], file_path: str, scale_factor: float, version: int, + text_mode: bool, imperial_units: bool) -> None: + """Exports a STEP file with extruded drillings + + Parameters: + elements: elements + file_path: file_path + scale_factor: scale_factor + version: version + text_mode: text_mode + imperial_units: imperial_units + + Returns: + None + """ + +``` + +#### export_sat_file_cut_drillings + +```python +def export_sat_file_cut_drillings(elements: List[int], file_path: str, + scale_factor: float, binary: bool, version: int) ->None: + """export sat file cut drillings + + Parameters: + elements: elements + file_path: file_path + scale_factor: scale_factor + binary: binary + version: version + + Returns: + None + """ + +``` + +#### upload_to_bim_team_and_create_share_link + +```python +def upload_to_bim_team_and_create_share_link(elements: None + ) ->bim_team_upload_result: + """upload to bim team and create share link + + Parameters: + elements: elements + + Returns: + bim_team_upload_result + """ + +``` + ## New Items ### Functions visualization_controller #### enter_working_plane @@ -71,3 +145,4 @@ def enter_working_plane(plane_normal: point_3d, plane_origin: point_3d) ->None: """ ``` + diff --git a/mkdocs.yml b/mkdocs.yml index 8d1f11f..d6a52bd 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -53,6 +53,7 @@ nav: - Layer Settings: documentation/layer_settings.md - Text Object Options: documentation/text_object_options.md - Window Geometry: documentation/window_geometry.md + - BIMteam Upload Result: documentation/bim_team_upload_result.md - Connector Axis Controller: documentation/connector_axis_controller.md - Dimension Controller: documentation/dimension_controller.md - Element Controller: documentation/element_controller.md diff --git a/src/cadwork/bim_team_upload_result.pyi b/src/cadwork/bim_team_upload_result.pyi new file mode 100644 index 0000000..56f41ab --- /dev/null +++ b/src/cadwork/bim_team_upload_result.pyi @@ -0,0 +1,17 @@ +from src.cadwork.bim_team_upload_result_code import bim_team_upload_result_code + + +class bim_team_upload_result: + """bim team upload result + """ + + def __init__(self): + """ + Instance of the bim_team_upload_result class. + + Attributes: + upload_result_code (bim_team_upload_result_code): The result code of the upload. + share_link (str): The share link for the uploaded BIM team result. + """ + self.upload_result_code = bim_team_upload_result_code.ok + self.share_link = "" diff --git a/src/cadwork/bim_team_upload_result_code.pyi b/src/cadwork/bim_team_upload_result_code.pyi new file mode 100644 index 0000000..344d7f2 --- /dev/null +++ b/src/cadwork/bim_team_upload_result_code.pyi @@ -0,0 +1,26 @@ +from enum import IntEnum, unique + + +@unique +class bim_team_upload_result_code(IntEnum): + """bim team upload result code + + Examples: + >>> cadwork.bim_team_upload_result_code.ok + ok + """ + ok = 0 + """""" + error_general_error = 1 + """""" + error_too_many_models = 2 + """""" + error_insufficient_storage = 3 + """""" + error_invalid_project_id = 4 + """""" + error_authentication_failed = 5 + """""" + + def __int__(self) -> int: + return self.value diff --git a/src/element_controller/__init__.pyi b/src/element_controller/__init__.pyi index 79253e5..1aff9ee 100644 --- a/src/element_controller/__init__.pyi +++ b/src/element_controller/__init__.pyi @@ -1987,3 +1987,14 @@ def slice_elements_with_plane_and_get_new_elements(element: int, cut_plane_norma List[int] """ +def get_elements_in_collision(element: int) ->List[int]: + """get elements in collision + + Parameters: + element: element + + Returns: + List[int] + """ + + diff --git a/src/file_controller/__init__.pyi b/src/file_controller/__init__.pyi index c719900..c6ba66a 100644 --- a/src/file_controller/__init__.pyi +++ b/src/file_controller/__init__.pyi @@ -1,5 +1,7 @@ from typing import List from cadwork import point_3d +from cadwork.bim_team_upload_result import bim_team_upload_result + def get_last_error(error_code: int) -> str: """Gets the last error @@ -11,6 +13,7 @@ def get_last_error(error_code: int) -> str: error string """ + def export_stl_file(element_id_list: List[int], file_path: str) -> None: """Exports an STL file @@ -22,6 +25,7 @@ def export_stl_file(element_id_list: List[int], file_path: str) -> None: None """ + def import_step_file(file_path: str, scale_factor: float) -> List[int]: """Imports a STEP file @@ -33,6 +37,7 @@ def import_step_file(file_path: str, scale_factor: float) -> List[int]: imported element ID list """ + def import_step_file_with_message_option(file_path: str, scale_factor: float, hide_message: bool) -> List[int]: """Imports a STEP file @@ -45,6 +50,7 @@ def import_step_file_with_message_option(file_path: str, scale_factor: float, hi imported element ID list """ + def export_webgl(element_id_list: List[int], file_path: str) -> bool: """Exports a WebGL file @@ -56,6 +62,7 @@ def export_webgl(element_id_list: List[int], file_path: str) -> bool: did operation succeed """ + def export_3d_file(element_id_list: List[int], file_path: str) -> bool: """Exports a 3D file @@ -67,6 +74,7 @@ def export_3d_file(element_id_list: List[int], file_path: str) -> bool: did operation succeed """ + def import_sat_file(file_path: str, scale_factor: float, binary: bool) -> List[int]: """Imports an SAT file @@ -79,6 +87,7 @@ def import_sat_file(file_path: str, scale_factor: float, binary: bool) -> List[i imported element ID list """ + def import_3dc_file(file_path: str) -> List[int]: """Imports a 3DC file @@ -89,6 +98,7 @@ def import_3dc_file(file_path: str) -> List[int]: imported element ID list """ + def import_rhino_file(file_path: str, without_dialog: bool) -> List[int]: """Imports a Rhino file @@ -100,7 +110,9 @@ def import_rhino_file(file_path: str, without_dialog: bool) -> List[int]: imported element ID list """ -def export_step_file(element_list: List[int], file_path: str, scale_factor: float, version: int, text_mode: bool) -> None: + +def export_step_file(element_list: List[int], file_path: str, scale_factor: float, version: int, + text_mode: bool) -> None: """Exports a STEP file Parameters: @@ -114,6 +126,7 @@ def export_step_file(element_list: List[int], file_path: str, scale_factor: floa None """ + def import_3dz_file(file_path: str) -> None: """Imports a 3DZ file @@ -124,6 +137,7 @@ def import_3dz_file(file_path: str) -> None: None """ + def export_obj_file(elements: List[int], file_path: str) -> None: """Exports a OBJ file @@ -135,6 +149,7 @@ def export_obj_file(elements: List[int], file_path: str) -> None: None """ + def import_sat_file_silently(file_path: str, scale_factor: float, binary: bool) -> List[int]: """Imports a SAT File without messages @@ -147,6 +162,7 @@ def import_sat_file_silently(file_path: str, scale_factor: float, binary: bool) List[int] """ + def export_fbx_file(elements: List[int], file_path: str, fbx_format: int) -> None: """Exports a FBX file @@ -159,6 +175,7 @@ def export_fbx_file(elements: List[int], file_path: str, fbx_format: int) -> Non None """ + def clear_errors() -> None: """clear errors @@ -166,6 +183,7 @@ def clear_errors() -> None: None """ + def import_3dc_file_with_glide(file_path: str) -> List[int]: """Imports a 3DC file with glide @@ -176,6 +194,7 @@ def import_3dc_file_with_glide(file_path: str) -> List[int]: imported element ID list """ + def import_btl_file(file_path: str) -> None: """Imports a BTL file @@ -186,6 +205,7 @@ def import_btl_file(file_path: str) -> None: None """ + def export_3dc_file(element_id_list: List[int], file_path: str) -> None: """Exports a 3D file @@ -197,6 +217,7 @@ def export_3dc_file(element_id_list: List[int], file_path: str) -> None: None """ + def import_btl_file_for_nesting(file_path: str) -> None: """Imports a BTL file for nesting @@ -207,6 +228,7 @@ def import_btl_file_for_nesting(file_path: str) -> None: None """ + def export_btl_file_for_nesting(file_path: str) -> None: """Exports a BTL file for nesting @@ -217,7 +239,9 @@ def export_btl_file_for_nesting(file_path: str) -> None: None """ -def export_rhino_file(element_id_list: List[int], file_path: str, version: int, use_default_assignment: bool, write_standard_attributes: bool) -> None: + +def export_rhino_file(element_id_list: List[int], file_path: str, version: int, use_default_assignment: bool, + write_standard_attributes: bool) -> None: """Exports a 3dm rhino file Parameters: @@ -231,6 +255,7 @@ def export_rhino_file(element_id_list: List[int], file_path: str, version: int, None """ + def import_bxf_file(file_path: str, insert_position: point_3d) -> List[int]: """import bxf file @@ -242,6 +267,7 @@ def import_bxf_file(file_path: str, insert_position: point_3d) -> List[int]: List[int] """ + def get_blum_export_path() -> str: """get blum export path @@ -249,6 +275,7 @@ def get_blum_export_path() -> str: str """ + def set_blum_export_path(path: str) -> None: """set blum export path @@ -259,6 +286,7 @@ def set_blum_export_path(path: str) -> None: None """ + def export_sat_file(elements: List[int], file_path: str, scale_factor: float, binary: bool, version: int) -> None: """exports a SAT File @@ -273,6 +301,7 @@ def export_sat_file(elements: List[int], file_path: str, scale_factor: float, bi None """ + def export_glb_file(elements: List[int], file_path: str) -> None: """exports a GLB File @@ -284,6 +313,7 @@ def export_glb_file(elements: List[int], file_path: str) -> None: None """ + def import_variant_file(file_path: str, insert_position: point_3d) -> List[int]: """imports a variant by .val-File @@ -295,6 +325,7 @@ def import_variant_file(file_path: str, insert_position: point_3d) -> List[int]: imported element ID list """ + def import_element_light(a0: str, a1: point_3d) -> int: """import element light @@ -306,7 +337,10 @@ def import_element_light(a0: str, a1: point_3d) -> int: int """ -def export_rhino_file_with_options(element_id_list: List[int], file_path: str, version: int, use_default_assignment: bool, write_standard_attributes: bool, rhino_options: None) -> None: + +def export_rhino_file_with_options(element_id_list: List[int], file_path: str, version: int, + use_default_assignment: bool, write_standard_attributes: bool, + rhino_options: None) -> None: """exports elements to a rhino 3dm file based on the export options Parameters: @@ -321,6 +355,7 @@ def export_rhino_file_with_options(element_id_list: List[int], file_path: str, v None """ + def import_3dc_file_with_options(file_path: str, import3dc_options: None) -> List[int]: """imports a 3d or a 3dc file depending on the import options @@ -332,13 +367,15 @@ def import_3dc_file_with_options(file_path: str, import3dc_options: None) -> Lis imported element ID list """ -def get_import_3dc_options() -> import_3dc_options: + +def get_import_3dc_options() -> 'import_3dc_options': """get import 3dc options Returns: import_3dc_options """ + def load_webgl_preset_file(file_path: str) -> None: """loads a preset file for the WebGl export @@ -349,7 +386,26 @@ def load_webgl_preset_file(file_path: str) -> None: None """ -def export_step_file_extrude_drillings(elements: List[int], file_path: str, scale_factor: float, version: int, text_mode: bool, imperial_units: bool) -> None: + +def export_step_file_extrude_drillings(elements: List[int], file_path: str, scale_factor: float, version: int, + text_mode: bool, imperial_units: bool) -> None: + """Exports a STEP file with extruded drillings + + Parameters: + elements: elements + file_path: file_path + scale_factor: scale_factor + version: version + text_mode: text_mode + imperial_units: imperial_units + + Returns: + None + """ + + +def export_step_file_cut_drillings(elements: List[int], file_path: str, scale_factor: float, version: int, + text_mode: bool, imperial_units: bool) -> None: """Exports a STEP file with extruded drillings Parameters: @@ -364,3 +420,30 @@ def export_step_file_extrude_drillings(elements: List[int], file_path: str, scal None """ + +def export_sat_file_cut_drillings(elements: List[int], file_path: str, + scale_factor: float, binary: bool, version: int) -> None: + """export sat file cut drillings + + Parameters: + elements: elements + file_path: file_path + scale_factor: scale_factor + binary: binary + version: version + + Returns: + None + """ + + +def upload_to_bim_team_and_create_share_link(elements: None + ) -> bim_team_upload_result: + """upload to bim team and create share link + + Parameters: + elements: elements + + Returns: + bim_team_upload_result + """ diff --git a/src/utility_controller/__init__.pyi b/src/utility_controller/__init__.pyi index 43ddc4a..fc804c2 100644 --- a/src/utility_controller/__init__.pyi +++ b/src/utility_controller/__init__.pyi @@ -3,6 +3,7 @@ from typing import Tuple from cadwork import point_3d from cadwork import window_geometry + def get_last_error(error_code: int) -> str: """Gets the last error @@ -13,6 +14,7 @@ def get_last_error(error_code: int) -> str: error string """ + def get_3d_version() -> int: """Gets the 3D version @@ -20,6 +22,7 @@ def get_3d_version() -> int: 3D version """ + def get_3d_build() -> int: """Gets the 3D build @@ -27,6 +30,7 @@ def get_3d_build() -> int: 3D build """ + def get_3d_file_path() -> str: """Gets the 3D file path @@ -34,6 +38,7 @@ def get_3d_file_path() -> str: 3D file path """ + def set_project_data(element_id: str, data: str) -> None: """Sets the project data @@ -45,6 +50,7 @@ def set_project_data(element_id: str, data: str) -> None: None """ + def print_error(message: str) -> None: """Prints an error @@ -55,6 +61,7 @@ def print_error(message: str) -> None: None """ + def get_language() -> str: """Gets the 3D language @@ -62,6 +69,7 @@ def get_language() -> str: 3D language """ + def print_message(message: str, column: int) -> None: """Prints a message @@ -73,6 +81,7 @@ def print_message(message: str, column: int) -> None: None """ + def get_user_int(message: str) -> int: """Prompts the user for an integer @@ -83,6 +92,7 @@ def get_user_int(message: str) -> int: user integer """ + def get_user_double(message: str) -> float: """Prompts the user for a double @@ -93,6 +103,7 @@ def get_user_double(message: str) -> float: user double """ + def get_user_bool(message: str, default_yes: bool) -> bool: """Prompts the user for a boolean @@ -104,6 +115,7 @@ def get_user_bool(message: str, default_yes: bool) -> bool: user boolean """ + def get_user_string(message: str) -> str: """Prompts the user for a string @@ -114,6 +126,7 @@ def get_user_string(message: str) -> str: user string """ + def set_project_name(project_name: str) -> None: """Sets the project name @@ -124,6 +137,7 @@ def set_project_name(project_name: str) -> None: None """ + def set_project_number(project_number: str) -> None: """Sets the project number @@ -134,6 +148,7 @@ def set_project_number(project_number: str) -> None: None """ + def set_project_part(project_part: str) -> None: """Sets the project part @@ -144,6 +159,7 @@ def set_project_part(project_part: str) -> None: None """ + def set_project_architect(project_architect: str) -> None: """Sets the project architect @@ -154,6 +170,7 @@ def set_project_architect(project_architect: str) -> None: None """ + def set_project_customer(project_customer: str) -> None: """Sets the project customer @@ -164,6 +181,7 @@ def set_project_customer(project_customer: str) -> None: None """ + def set_project_designer(project_designer: str) -> None: """Sets the project designer @@ -174,6 +192,7 @@ def set_project_designer(project_designer: str) -> None: None """ + def set_project_deadline(project_deadline: str) -> None: """Sets the project deadline @@ -184,6 +203,7 @@ def set_project_deadline(project_deadline: str) -> None: None """ + def set_project_user_attribute(number: int, user_attribute: str) -> None: """Sets the project user attribute @@ -195,6 +215,7 @@ def set_project_user_attribute(number: int, user_attribute: str) -> None: None """ + def set_project_user_attribute_name(number: int, user_attribute_name: str) -> None: """Sets the project user attribute name @@ -206,6 +227,7 @@ def set_project_user_attribute_name(number: int, user_attribute_name: str) -> No None """ + def set_project_latitude(latitude: float) -> None: """Sets the project latitude @@ -216,6 +238,7 @@ def set_project_latitude(latitude: float) -> None: None """ + def set_project_longitude(longitude: float) -> None: """Sets the project longitude @@ -226,6 +249,7 @@ def set_project_longitude(longitude: float) -> None: None """ + def set_project_address(address: str) -> None: """Sets the project address @@ -236,6 +260,7 @@ def set_project_address(address: str) -> None: None """ + def set_project_postal_code(postal_code: str) -> None: """Sets the project postal code @@ -246,6 +271,7 @@ def set_project_postal_code(postal_code: str) -> None: None """ + def set_project_city(city: str) -> None: """Sets the project city @@ -256,6 +282,7 @@ def set_project_city(city: str) -> None: None """ + def set_project_country(country: str) -> None: """Sets the project country @@ -266,6 +293,7 @@ def set_project_country(country: str) -> None: None """ + def get_user_file_from_dialog(name_filter: str) -> str: """Gets a file with a dialog @@ -276,6 +304,7 @@ def get_user_file_from_dialog(name_filter: str) -> str: file path """ + def get_client_number() -> str: """Gets the client number @@ -283,6 +312,7 @@ def get_client_number() -> str: client number """ + def get_user_point() -> point_3d: """Gets a point from the user @@ -290,6 +320,7 @@ def get_user_point() -> point_3d: user point """ + def disable_auto_display_refresh() -> None: """Disables automatic display refresh @@ -297,6 +328,7 @@ def disable_auto_display_refresh() -> None: None """ + def enable_auto_display_refresh() -> None: """Enables automatic display refresh @@ -304,6 +336,7 @@ def enable_auto_display_refresh() -> None: None """ + def create_new_guid() -> str: """Creates a new GUID @@ -311,6 +344,7 @@ def create_new_guid() -> str: GUID """ + def print_to_console(message: str) -> None: """Prints a message to the console @@ -321,6 +355,7 @@ def print_to_console(message: str) -> None: None """ + def export_screen_to_image(file_path: str, factor: int) -> None: """Exports the screen to an image @@ -332,6 +367,7 @@ def export_screen_to_image(file_path: str, factor: int) -> None: None """ + def get_new_user_file_from_dialog(name_filter: str) -> str: """Gets a new file with a dialog @@ -342,6 +378,7 @@ def get_new_user_file_from_dialog(name_filter: str) -> str: file path """ + def api_autostart(api_name: str, option: int) -> int: """api autostart @@ -353,6 +390,7 @@ def api_autostart(api_name: str, option: int) -> int: int """ + def enable_autostart(api_name: str) -> None: """enable autostart @@ -363,6 +401,7 @@ def enable_autostart(api_name: str) -> None: None """ + def disable_autostart(api_name: str) -> None: """disable autostart @@ -373,6 +412,7 @@ def disable_autostart(api_name: str) -> None: None """ + def check_autostart(api_name: str) -> bool: """check autostart @@ -383,6 +423,7 @@ def check_autostart(api_name: str) -> bool: bool """ + def delete_project_data(element_id: str) -> None: """Deletes the project data @@ -393,6 +434,7 @@ def delete_project_data(element_id: str) -> None: None """ + def run_external_program(name: str) -> bool: """Runs a 3D external program @@ -403,6 +445,7 @@ def run_external_program(name: str) -> bool: external program return """ + def save_3d_file_silently() -> None: """Saves the 3D file silently @@ -410,6 +453,7 @@ def save_3d_file_silently() -> None: None """ + def get_licence_first_part() -> str: """Gets the first part of the licence @@ -417,6 +461,7 @@ def get_licence_first_part() -> str: first part of licence """ + def get_licence_second_part() -> str: """Gets the second part of the licence @@ -424,6 +469,7 @@ def get_licence_second_part() -> str: second part of licence """ + def show_progress_bar() -> None: """Shows a ProgressBar in the CommandBar @@ -431,6 +477,7 @@ def show_progress_bar() -> None: None """ + def update_progress_bar(value: int) -> None: """Updates the ProgressBar with a value @@ -441,6 +488,7 @@ def update_progress_bar(value: int) -> None: None """ + def hide_progress_bar() -> None: """Hides the ProgressBar @@ -448,6 +496,7 @@ def hide_progress_bar() -> None: None """ + def get_user_color(initial_color: int) -> int: """Gets a color choosen by the user @@ -458,6 +507,7 @@ def get_user_color(initial_color: int) -> int: the colornumber """ + def get_3d_linear_units() -> str: """Gets the current linear units @@ -465,6 +515,7 @@ def get_3d_linear_units() -> str: str """ + def get_3d_linear_display_units() -> str: """Gets the current display units @@ -472,6 +523,7 @@ def get_3d_linear_display_units() -> str: str """ + def get_3d_angular_units() -> str: """Gets the current angular units @@ -479,6 +531,7 @@ def get_3d_angular_units() -> str: str """ + def get_3d_angular_display_units() -> str: """Gets the current angular display units @@ -486,6 +539,7 @@ def get_3d_angular_display_units() -> str: str """ + def get_3d_build_date() -> str: """Gets the current build date @@ -493,6 +547,7 @@ def get_3d_build_date() -> str: str """ + def set_project_elevation(elevation: float) -> None: """Sets the project elevation @@ -503,6 +558,7 @@ def set_project_elevation(elevation: float) -> None: None """ + def clear_errors() -> None: """clear errors @@ -510,6 +566,7 @@ def clear_errors() -> None: None """ + def push_check_and_query_data() -> None: """push check and query data @@ -517,6 +574,7 @@ def push_check_and_query_data() -> None: None """ + def pop_check_and_query_data() -> None: """pop check and query data @@ -524,6 +582,7 @@ def pop_check_and_query_data() -> None: None """ + def change_check_and_query_data_to_no_queries() -> None: """change check and query data to no queries @@ -531,6 +590,7 @@ def change_check_and_query_data_to_no_queries() -> None: None """ + def change_check_and_query_data_to_queries() -> None: """change check and query data to queries @@ -538,6 +598,7 @@ def change_check_and_query_data_to_queries() -> None: None """ + def is_direct_info_enabled() -> bool: """is direct info enabled @@ -545,6 +606,7 @@ def is_direct_info_enabled() -> bool: bool """ + def enable_direct_info() -> None: """enable direct info @@ -552,6 +614,7 @@ def enable_direct_info() -> None: None """ + def disable_direct_info() -> None: """disable direct info @@ -559,6 +622,7 @@ def disable_direct_info() -> None: None """ + def load_attribute_display_settings(file_path: str) -> None: """load attribute display settings @@ -569,6 +633,7 @@ def load_attribute_display_settings(file_path: str) -> None: None """ + def set_project_description(description: str) -> None: """set project description @@ -579,6 +644,7 @@ def set_project_description(description: str) -> None: None """ + def start_project_data_dialog() -> None: """start project data dialog @@ -586,6 +652,7 @@ def start_project_data_dialog() -> None: None """ + def init_LxSDK() -> None: """init LxSDK @@ -593,6 +660,7 @@ def init_LxSDK() -> None: None """ + def load_element_attribute_display_settings(file_path: str, elements: List[int]) -> None: """load element attribute display settings @@ -604,6 +672,7 @@ def load_element_attribute_display_settings(file_path: str, elements: List[int]) None """ + def get_global_x_offset() -> float: """get global x offset @@ -611,6 +680,7 @@ def get_global_x_offset() -> float: float """ + def set_global_x_offset(offset: float) -> None: """set global x offset @@ -621,6 +691,7 @@ def set_global_x_offset(offset: float) -> None: None """ + def get_global_y_offset() -> float: """get global y offset @@ -628,6 +699,7 @@ def get_global_y_offset() -> float: float """ + def set_global_y_offset(offset: float) -> None: """set global y offset @@ -638,6 +710,7 @@ def set_global_y_offset(offset: float) -> None: None """ + def get_global_z_offset() -> float: """get global z offset @@ -645,6 +718,7 @@ def get_global_z_offset() -> float: float """ + def set_global_z_offset(offset: float) -> None: """set global z offset @@ -655,6 +729,7 @@ def set_global_z_offset(offset: float) -> None: None """ + def show_north_arrow() -> None: """show north arrow @@ -662,6 +737,7 @@ def show_north_arrow() -> None: None """ + def hide_north_arrow() -> None: """hide north arrow @@ -669,6 +745,7 @@ def hide_north_arrow() -> None: None """ + def is_north_arrow_visible() -> bool: """is north arrow visible @@ -676,6 +753,7 @@ def is_north_arrow_visible() -> bool: bool """ + def get_north_angle() -> float: """get north angle @@ -683,6 +761,7 @@ def get_north_angle() -> float: float """ + def set_north_angle(north_angle: float) -> None: """set north angle @@ -693,6 +772,7 @@ def set_north_angle(north_angle: float) -> None: None """ + def get_user_file_from_dialog_in_path(name_filter: str, path: str) -> str: """get user file from dialog in path @@ -704,6 +784,7 @@ def get_user_file_from_dialog_in_path(name_filter: str, path: str) -> str: str """ + def get_new_user_file_from_dialog_in_path(name_filter: str, path: str) -> str: """get new user file from dialog in path @@ -715,6 +796,7 @@ def get_new_user_file_from_dialog_in_path(name_filter: str, path: str) -> str: str """ + def enable_update_variant() -> None: """enable update variant @@ -722,6 +804,7 @@ def enable_update_variant() -> None: None """ + def disable_update_variant() -> None: """disable update variant @@ -729,6 +812,7 @@ def disable_update_variant() -> None: None """ + def get_user_points() -> List[point_3d]: """get user points @@ -736,6 +820,7 @@ def get_user_points() -> List[point_3d]: List[point_3d] """ + def get_user_points_with_count(a0: int) -> List[point_3d]: """get user points with count @@ -746,6 +831,7 @@ def get_user_points_with_count(a0: int) -> List[point_3d]: List[point_3d] """ + def get_user_path_from_dialog() -> str: """get user path from dialog @@ -753,6 +839,7 @@ def get_user_path_from_dialog() -> str: str """ + def get_user_path_from_dialog_in_path(a0: str) -> str: """get user path from dialog in path @@ -763,6 +850,7 @@ def get_user_path_from_dialog_in_path(a0: str) -> str: str """ + def execute_shortcut(a0: int, a1: int) -> None: """execute shortcut @@ -774,6 +862,7 @@ def execute_shortcut(a0: int, a1: int) -> None: None """ + def run_external_program_from_custom_directory(file_path: str) -> bool: """Runs a 3D external program from a custom file path @@ -784,6 +873,7 @@ def run_external_program_from_custom_directory(file_path: str) -> bool: external program return """ + def get_3d_file_name() -> str: """Gets the 3D file name @@ -791,6 +881,7 @@ def get_3d_file_name() -> str: 3D file name """ + def get_project_data(element_id: str) -> str: """Gets the project data @@ -801,6 +892,7 @@ def get_project_data(element_id: str) -> str: project data """ + def get_project_name() -> str: """Gets the project name @@ -808,6 +900,7 @@ def get_project_name() -> str: project name """ + def get_project_part() -> str: """Sets the project part @@ -815,6 +908,7 @@ def get_project_part() -> str: project part """ + def get_project_architect() -> str: """Gets the project architect @@ -822,6 +916,7 @@ def get_project_architect() -> str: project architect """ + def get_project_number() -> str: """Gets the project number @@ -829,6 +924,7 @@ def get_project_number() -> str: project number """ + def get_project_customer() -> str: """Gets the project customer @@ -836,6 +932,7 @@ def get_project_customer() -> str: project customer """ + def get_project_designer() -> str: """Gets the project designer @@ -843,6 +940,7 @@ def get_project_designer() -> str: project designer """ + def get_project_deadline() -> str: """Gets the project deadline @@ -850,6 +948,7 @@ def get_project_deadline() -> str: project deadline """ + def get_project_user_attribute(number: int) -> str: """Gets the project user attribute @@ -860,6 +959,7 @@ def get_project_user_attribute(number: int) -> str: project user attribute """ + def get_project_user_attribute_name(number: int) -> str: """Gets the project user attribute name @@ -870,6 +970,7 @@ def get_project_user_attribute_name(number: int) -> str: project user attribute name """ + def get_project_latitude() -> float: """Gets the project latitude @@ -877,6 +978,7 @@ def get_project_latitude() -> float: project latitude """ + def get_project_longitude() -> float: """Gets the project longitude @@ -884,6 +986,7 @@ def get_project_longitude() -> float: project longitude """ + def get_project_postal_code() -> str: """Gets the project postal code @@ -891,6 +994,7 @@ def get_project_postal_code() -> str: project postal code """ + def get_project_address() -> str: """Gets the project address @@ -898,6 +1002,7 @@ def get_project_address() -> str: project address """ + def get_project_city() -> str: """Gets the project city @@ -905,6 +1010,7 @@ def get_project_city() -> str: project city """ + def get_project_country() -> str: """Gets the project country @@ -912,6 +1018,7 @@ def get_project_country() -> str: project country """ + def get_project_elevation() -> float: """Gets the project elevation @@ -919,6 +1026,7 @@ def get_project_elevation() -> float: project elevation """ + def get_project_description() -> str: """get project description @@ -926,6 +1034,7 @@ def get_project_description() -> str: str """ + def get_project_guid() -> str: """Gets the project GUID @@ -933,6 +1042,7 @@ def get_project_guid() -> str: project GUID """ + def get_3d_userprofil_path() -> str: """Gets the 3D userprofil path @@ -940,6 +1050,7 @@ def get_3d_userprofil_path() -> str: the 3D userprofil path """ + def get_plugin_path() -> str: """get plugin path @@ -947,6 +1058,7 @@ def get_plugin_path() -> str: str """ + def get_millimetre_from_imperial_string(value: str) -> float: """get millimetre from imperial string @@ -957,6 +1069,7 @@ def get_millimetre_from_imperial_string(value: str) -> float: float """ + def get_imperial_string_from_millimetre(value: float) -> str: """get imperial string from millimetre @@ -967,6 +1080,7 @@ def get_imperial_string_from_millimetre(value: float) -> str: str """ + def get_user_catalog_path() -> str: """get user catalog path @@ -974,6 +1088,7 @@ def get_user_catalog_path() -> str: str """ + def get_3d_hwnd() -> int: """Gets the 3D HWND @@ -981,6 +1096,7 @@ def get_3d_hwnd() -> int: 3D HWND """ + def close_cadwork_document_saved() -> None: """close cadwork saved @@ -988,6 +1104,7 @@ def close_cadwork_document_saved() -> None: None """ + def close_cadwork_document_unsaved() -> None: """close cadwork document unsaved @@ -995,6 +1112,7 @@ def close_cadwork_document_unsaved() -> None: None """ + def get_use_of_global_coordinates() -> bool: """get use of global coordinates @@ -1002,6 +1120,7 @@ def get_use_of_global_coordinates() -> bool: bool """ + def set_use_of_global_coordinates(use_of_global_coordinates: bool) -> None: """Sets the use of global coordinates @@ -1012,6 +1131,7 @@ def set_use_of_global_coordinates(use_of_global_coordinates: bool) -> None: None """ + def get_global_origin() -> point_3d: """Gets the global origin @@ -1019,6 +1139,7 @@ def get_global_origin() -> point_3d: global origin """ + def set_global_origin(global_origin: point_3d) -> None: """Sets the global origin @@ -1029,6 +1150,7 @@ def set_global_origin(global_origin: point_3d) -> None: None """ + def create_snapshot() -> str: """get snapshot from screen @@ -1036,6 +1158,7 @@ def create_snapshot() -> str: snapshot """ + def get_3d_gui_upper_left_screen_coordinates() -> Tuple[int, int]: """get 3d gui upper left screen coordinates @@ -1043,6 +1166,7 @@ def get_3d_gui_upper_left_screen_coordinates() -> Tuple[int, int]: coordinates of the upper left corner of the 3D GUI """ + def get_3d_main_window_geometry() -> 'window_geometry': """get 3d main window geometry @@ -1050,6 +1174,7 @@ def get_3d_main_window_geometry() -> 'window_geometry': window geometry """ + def get_project_data_keys() -> List[str]: """get project data keys @@ -1057,6 +1182,7 @@ def get_project_data_keys() -> List[str]: List[str] """ + def get_user_int_with_default_value(message: str, default_value: int) -> int: """get user int with default value @@ -1068,6 +1194,7 @@ def get_user_int_with_default_value(message: str, default_value: int) -> int: int """ + def get_user_double_with_default_value(message: str, default_value: float) -> float: """get user double with default value @@ -1079,6 +1206,7 @@ def get_user_double_with_default_value(message: str, default_value: float) -> fl float """ + def get_user_string_with_default_value(message: str, default_value: str) -> str: """get user string with default value @@ -1090,3 +1218,14 @@ def get_user_string_with_default_value(message: str, default_value: str) -> str: str """ + +def enter_working_plane(plane_normal: point_3d, plane_origin: point_3d) -> None: + """enter working plane + + Parameters: + plane_normal: plane_normal + plane_origin: plane_origin + + Returns: + None + """ From ebbb10d99dd478afe8d5169388850e2b9693b2d2 Mon Sep 17 00:00:00 2001 From: Michael Brunner Date: Wed, 2 Oct 2024 09:46:12 +0200 Subject: [PATCH 2/3] - remove `enter_working_plane`function from wrong controller --- src/utility_controller/__init__.pyi | 11 ----------- src/visualization_controller/__init__.pyi | 1 + 2 files changed, 1 insertion(+), 11 deletions(-) diff --git a/src/utility_controller/__init__.pyi b/src/utility_controller/__init__.pyi index fc804c2..d0e9387 100644 --- a/src/utility_controller/__init__.pyi +++ b/src/utility_controller/__init__.pyi @@ -1218,14 +1218,3 @@ def get_user_string_with_default_value(message: str, default_value: str) -> str: str """ - -def enter_working_plane(plane_normal: point_3d, plane_origin: point_3d) -> None: - """enter working plane - - Parameters: - plane_normal: plane_normal - plane_origin: plane_origin - - Returns: - None - """ diff --git a/src/visualization_controller/__init__.pyi b/src/visualization_controller/__init__.pyi index a9afc60..63ca42e 100644 --- a/src/visualization_controller/__init__.pyi +++ b/src/visualization_controller/__init__.pyi @@ -511,3 +511,4 @@ def enter_working_plane(plane_normal: point_3d, plane_origin: point_3d) ->None: Returns: None """ + From 18678d8d963bc7ce1c573843b2c9d3a80a0a8cba Mon Sep 17 00:00:00 2001 From: Michael Brunner Date: Wed, 2 Oct 2024 10:55:32 +0200 Subject: [PATCH 3/3] - update cwapi3d package version --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 8c7a2b5..971f472 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "cwapi3d" -version = "30.0.533" +version = "30.0.593" authors = [{ name = "Cadwork", email = "it@cadwork.ca" }] requires-python = ">= 3.10" description = 'Python bindings for CwAPI3D'