__init__.py 826 B

123456789101112131415161718192021222324
  1. # Copyright (c) 2018 Ultimaker B.V.
  2. # Cura is released under the terms of the LGPLv3 or higher.
  3. from UM.PluginRegistry import PluginRegistry
  4. from cura.API.Interface.Settings import Settings
  5. ## The Interface class serves as a common root for the specific API
  6. # methods for each interface element.
  7. #
  8. # Usage:
  9. # ``from cura.API import CuraAPI
  10. # api = CuraAPI()
  11. # api.interface.settings.addContextMenuItem()
  12. # api.interface.viewport.addOverlay() # Not implemented, just a hypothetical
  13. # api.interface.toolbar.getToolButtonCount() # Not implemented, just a hypothetical
  14. # # etc.``
  15. class Interface:
  16. # For now we use the same API version to be consistent.
  17. VERSION = PluginRegistry.APIVersion
  18. # API methods specific to the settings portion of the UI
  19. settings = Settings()