Skip to main content

xml/json view support for toga

Project description

Toga-View

xml/json view support for toga




🛠️ Features

  • Toga View Format: support .ui.xml/.ui.json format file.
  • Parse/Archive
    • support parse ui file and archive python to ui file
    • support parse ui file into python file
    • support transpile ui file between .ui.xml and .ui.json

💿 Installation

  • install from git(latest)
pip install git@github.com:somehitDev/toga-view.git
  • pypi
pip install toga-view

📑 Usage

  • cli
# parse
toga_view_cli parse {ui_file} -o {py_file}
# transpile
toga_view_cli transpile {ui_file} -o {ui_file of different ext}
  • python
# parse(into toga.Widget)
XmlParser.parse_file("{ui_file}")
JsonParser.parse_file("{ui_file}")
# parse(into python script)
XmlParser.parse_file_to_script("{ui_file}", "{widget_class_name}")
JsonParser.parse_file_to_script("{ui_file}", "{widget_class_name}")

# archive(into element)
XmlArchiver.archive({toga.Widget})
JsonArchiver.archive({toga.Widget})
# archive(into ui file)
XmlArchiver.archive_to_file({toga.Widget}, "{ui_file}")
JsonArchiver.archive_to_file({toga.Widget}, "{ui_file}")

Project Structure

  • toga_view/: toga-view source.
  • tests/: examples.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

toga_view-0.0.1.tar.gz (10.0 kB view hashes)

Uploaded Source

Built Distribution

toga_view-0.0.1-py3-none-any.whl (11.6 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page