Skip to content

LibraryBitmapPreview

Implementation of the library bitmap preview

Functions:

create_libary_bitmap_preview

create_libary_bitmap_preview(png_file_name: str) -> ModelEleList

deprecated function with typo

Parameters:

  • png_file_name (str) –

    pnt file name

Returns:

  • ModelEleList

    list with the model elements for the preview

create_library_bitmap_preview

create_library_bitmap_preview(png_file_name: str) -> ModelEleList

This function creates the preview objects, which are needed to draw a bitmap inside the preview window of the library

Parameters:

  • png_file_name (str) –

    full name of the png file

Returns:

  • ModelEleList

    list with the model elements for the preview

get_file_name_for_active_gui_theme

get_file_name_for_active_gui_theme(png_file_name: str) -> str

Returns a file name for active gui theme using '_dark' suffix for dark mode

Parameters:

  • png_file_name (str) –

    Full name of the png file.

Returns:

  • str

    Modified file name with '_dark' suffix if the dark mode is active and the file exists,

  • str

    otherwise the original file name.

Placeholder