Skip to content

Commit

Permalink
Merge pull request #185 from Ocupe/restruc_toga
Browse files Browse the repository at this point in the history
The Big Restructure of Toga
  • Loading branch information
freakboy3742 committed Sep 23, 2017
2 parents a7bd3a0 + 15943f3 commit fb3702e
Show file tree
Hide file tree
Showing 302 changed files with 6,971 additions and 4,732 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
*~
.*.sw[op]
*.egg-info
.eggs
.coverage
dist
build
Expand Down
31 changes: 27 additions & 4 deletions README.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,29 @@
.. image:: http://pybee.org/project/projects/libraries/toga/toga.png
:width: 72px
:target: https://pybee.org/toga

Toga
====

.. image:: https://img.shields.io/pypi/pyversions/toga.svg
:target: https://pypi.python.org/pypi/toga

.. image:: https://img.shields.io/pypi/v/toga.svg
:target: https://pypi.python.org/pypi/toga

.. image:: https://img.shields.io/pypi/status/toga.svg
:target: https://pypi.python.org/pypi/toga

.. image:: https://img.shields.io/pypi/l/toga.svg
:target: https://github.com/pybee/toga/blob/master/LICENSE

.. image:: https://beekeeper.herokuapp.com/projects/pybee/batavia/shield
:target: https://beekeeper.herokuapp.com/projects/pybee/batavia

.. image:: https://badges.gitter.im/pybee/general.svg
:target: https://gitter.im/pybee/general


A Python native, OS native GUI toolkit.

Prerequisites
Expand All @@ -16,9 +39,9 @@ Minimum requirements
* If you're on Linux, you need to have GTK+ 3.10 or later. This is the version
that ships starting with Ubuntu 14.04 and Fedora 20. You also need to install
the Python 3 bindings to GTK+.

* We're working on Windows support, but not all features and widgets are supported. At a minimum, you'll need Python 3 and .NET Framework 4. This has been tested on Windows 10, but should work on 7 and 8. Pull requests, help and corrections are most welcome.

Optional extras
^^^^^^^^^^^^^^^

Expand All @@ -31,8 +54,8 @@ you'll need to install the following:
or ``apt-get install python3-gi gir1.2-webkit-3.0``

* **Fedora** ``dnf install python3-gobject pywebkitgtk``
or ``yum install python3-gobject pywebkitgtk``
or ``yum install python3-gobject pywebkitgtk``

Other distros should be similar, but feel free to send a pull request with updated dependencies if needed.

If these requirements aren't met, Toga either won't work at all, or won't have
Expand Down
69 changes: 69 additions & 0 deletions beekeeper.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
pull_request:
- beefore:
name: Prebuild checks
subtasks:
- eslint:
name: JavaScript lint checks
task: beefore-javascript
- pycodestyle:
name: Python lint checks
task: beefore
- core:
subtasks:
- py3.4:
name: Python 3.4 Core API tests
task: py34
environment:
TEST_DIR: src/core
SRC_DEPENDANTS: src/dummy
- py3.5:
name: Python 3.5 Core API tests
task: py35
environment:
TEST_DIR: src/core
SRC_DEPENDANTS: src/dummy
- py3.6:
name: Python 3.6 Core API tests
task: py36
environment:
TEST_DIR: src/core
SRC_DEPENDANTS: src/dummy
- implementations:
task: py34
subtasks:
- gtk:
name: GTK+ implementation compliance check
environment:
TEST_DIR: src/gtk
SRC_DEPENDANTS: src/core src/dummy
- winforms:
name: Winforms implementation compliance check
environment:
TEST_DIR: src/winforms
SRC_DEPENDANTS: src/core src/dummy
- cocoa:
name: macOS Cocoa implementation compliance check
environment:
TEST_DIR: src/cocoa
SRC_DEPENDANTS: src/core src/dummy
- iOS:
name: iOS implementation compliance check
environment:
TEST_DIR: src/iOS
SRC_DEPENDANTS: src/core src/dummy
- android:
name: Android implementation compliance check
environment:
TEST_DIR: src/android
SRC_DEPENDANTS: src/core src/dummy
- django:
name: Django implementation compliance check
environment:
TEST_DIR: src/django
SRC_DEPENDANTS: src/core src/dummy
push:
- smoke:
task: py34
name: Core API tests
environment:
TEST_DIR: src/core
Empty file modified demo/AUTHORS
100644 → 100755
Empty file.
Empty file modified demo/CONTRIBUTING.md
100644 → 100755
Empty file.
Empty file modified demo/LICENSE
100644 → 100755
Empty file.
Empty file modified demo/MANIFEST.in
100644 → 100755
Empty file.
Empty file modified demo/README.rst
100644 → 100755
Empty file.
Empty file modified demo/setup.py
100644 → 100755
Empty file.
2 changes: 1 addition & 1 deletion demo/toga_demo/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@
# __version__ = '1.2.3' # Final Release
# __version__ = '1.2.3.post1' # Post Release 1

__version__ = '0.2.15'
__version__ = '0.3.0.dev1'
Empty file modified demo/toga_demo/__main__.py
100644 → 100755
Empty file.
Empty file modified demo/toga_demo/app.py
100644 → 100755
Empty file.
Empty file modified demo/toga_demo/icons/brutus-32.png
100644 → 100755
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
13 changes: 12 additions & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@

# Add any Sphinx extension module names here, as strings. They can be extensions
# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
extensions = ['sphinx.ext.autodoc']
extensions = ['sphinx.ext.autodoc', 'sphinx.ext.napoleon', 'sphinx.ext.todo']

# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']
Expand Down Expand Up @@ -282,3 +282,14 @@
spelling_word_list_filename = 'spelling_wordlist'

spelling_ignore_pypi_package_names = True

# -- Options for Todos -------------------------------------------

# If this is True, todo and todolist produce output, else they produce nothing. The default is False.
todo_include_todos = True

# If this is True, todo emits a warning for each TODO entries. The default is False.
# todo_emit_warnings = False

# If this is True, todolist produce output without file path and line, The default is False.
# todo_link_only = False
40 changes: 21 additions & 19 deletions docs/reference/widgets.rst
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@ Toga includes a set of core widgets, that can be placed with a :doc:`Box </refer
==================== ============================================================ ====================================== ===================================================================
Component Usage Purpose Class
==================== ============================================================ ====================================== ===================================================================
Application :doc:`Documentation </reference/widgets/app>` Primary host for UI components :mod:`toga.interface.app.App`
Box :doc:`Documentation </reference/widgets/box>` Container for components :mod:`toga.interface.widgets.box.Box`
Font :doc:`Documentation </reference/widgets/font>` Fonts :mod:`toga.interface.font.Font`
Widget :doc:`Documentation </reference/widgets/widget>` Base class for widgets :mod:`toga.interface.widgets.base.Widget`
Window :doc:`Documentation </reference/widgets/window>` Window object :mod:`toga.interface.window.Window`
Application :doc:`Documentation </reference/widgets/app>` Primary host for UI components :mod:`toga.app.App`
Box :doc:`Documentation </reference/widgets/box>` Container for components :mod:`toga.widgets.box.Box`
Font :doc:`Documentation </reference/widgets/font>` Fonts :mod:`toga.font.Font`
Widget :doc:`Documentation </reference/widgets/widget>` Base class for widgets :mod:`toga.widgets.base.Widget`
Window :doc:`Documentation </reference/widgets/window>` Window object :mod:`toga.window.Window`
==================== ============================================================ ====================================== ===================================================================

---------------
Expand All @@ -27,17 +27,18 @@ General widgets
==================== ============================================================ ====================================== ===================================================================
Component Usage Purpose Class
==================== ============================================================ ====================================== ===================================================================
Button :doc:`Documentation </reference/widgets/button>` Basic clickable button :mod:`toga.interface.widgets.button.Button`
Image View :doc:`Documentation </reference/widgets/imageview>` Image Viewer :mod:`toga.interface.widgets.imageview.ImageView`
Label :doc:`Documentation </reference/widgets/label>` Text label :mod:`toga.interface.widgets.label.Label`
Multiline Text Input :doc:`Documentation </reference/widgets/multilinetextinput>` Multi-line Text Input field :mod:`toga.interface.widgets.multilinetextinput.MultilineTextInput`
Number Input :doc:`Documentation </reference/widgets/numberinput>` Number Input field :mod:`toga.interface.widgets.numberinput.NumberInput`
Option Container :doc:`Documentation </reference/widgets/optioncontainer>` Option Container :mod:`toga.interface.widgets.optioncontainer.OptionContainer`
Progress Bar :doc:`Documentation </reference/widgets/progressbar>` Progress Bar :mod:`toga.interface.widgets.progressbar.ProgressBar`
Selection :doc:`Documentation </reference/widgets/selection>` Selection :mod:`toga.interface.widgets.selection.Selection`
Text Input :doc:`Documentation </reference/widgets/textinput>` Text Input field :mod:`toga.interface.widgets.textinput.TextInput`
Table :doc:`Documentation </reference/widgets/table>` Table of data :mod:`toga.interface.widgets.table.Table`
Tree :doc:`Documentation </reference/widgets/tree>` Tree of data :mod:`toga.interface.widgets.tree.Tree`
Button :doc:`Documentation </reference/widgets/button>` Basic clickable button :mod:`toga.widgets.button.Button`
Image View :doc:`Documentation </reference/widgets/imageview>` Image Viewer :mod:`toga.widgets.imageview.ImageView`
Label :doc:`Documentation </reference/widgets/label>` Text label :mod:`toga.widgets.label.Label`
Multiline Text Input :doc:`Documentation </reference/widgets/multilinetextinput>` Multi-line Text Input field :mod:`toga.widgets.multilinetextinput.MultilineTextInput`
Number Input :doc:`Documentation </reference/widgets/numberinput>` Number Input field :mod:`toga.widgets.numberinput.NumberInput`
Option Container :doc:`Documentation </reference/widgets/optioncontainer>` Option Container :mod:`toga.widgets.optioncontainer.OptionContainer`
Progress Bar :doc:`Documentation </reference/widgets/progressbar>` Progress Bar :mod:`toga.widgets.progressbar.ProgressBar`
Selection :doc:`Documentation </reference/widgets/selection>` Selection :mod:`toga.widgets.selection.Selection`
Text Input :doc:`Documentation </reference/widgets/textinput>` Text Input field :mod:`toga.widgets.textinput.TextInput`
Table :doc:`Documentation </reference/widgets/table>` Table of data :mod:`toga.widgets.table.Table`
Tree :doc:`Documentation </reference/widgets/tree>` Tree of data :mod:`toga.widgets.tree.Tree`
Switch :doc:`Documentation </reference/widgets/switch>` Switch :mod:`toga.widgets.switch.Switch`
==================== ============================================================ ====================================== ===================================================================

--------------
Expand All @@ -47,7 +48,8 @@ Layout widgets
==================== ============================================================ ====================================== ===================================================================
Component Usage Purpose Class
==================== ============================================================ ====================================== ===================================================================
Scroll Container :doc:`Documentation </reference/widgets/scrollcontainer>` Scrollable Container :mod:`toga.interface.widgets.scrollcontainer.ScrollContainer`
Split Container :doc:`Documentation </reference/widgets/splitcontainer>` Split Container :mod:`toga.interface.widgets.splitcontainer.SplitContainer`
Web View :doc:`Documentation </reference/widgets/webview>` Web View :mod:`toga.interface.widgets.webview.WebView`
Scroll Container :doc:`Documentation </reference/widgets/scrollcontainer>` Scrollable Container :mod:`toga.widgets.scrollcontainer.ScrollContainer`
Split Container :doc:`Documentation </reference/widgets/splitcontainer>` Split Container :mod:`toga.widgets.splitcontainer.SplitContainer`
Option Container :doc:`Documentation </reference/widgets/optioncontainer>` Option Container :mod:`toga.widgets.optioncontainer.OptionContainer`
Web View :doc:`Documentation </reference/widgets/webview>` Web View :mod:`toga.widgets.webview.WebView`
==================== ============================================================ ====================================== ===================================================================
2 changes: 1 addition & 1 deletion docs/reference/widgets/app.rst
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ Supported Platforms
Reference
---------

.. autoclass:: toga.interface.app.App
.. autoclass:: toga.app.App
:members:
:undoc-members:
:inherited-members:
2 changes: 1 addition & 1 deletion docs/reference/widgets/box.rst
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ Supported Platforms
Reference
---------
.. autoclass:: toga.interface.widgets.box.Box
.. autoclass:: toga.widgets.box.Box
:members:
:undoc-members:
:inherited-members:
Expand Down
2 changes: 1 addition & 1 deletion docs/reference/widgets/button.rst
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ Supported Platforms
Reference
---------

.. autoclass:: toga.interface.widgets.button.Button
.. autoclass:: toga.widgets.button.Button
:members:
:undoc-members:
:inherited-members:
2 changes: 1 addition & 1 deletion docs/reference/widgets/font.rst
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ Supported Platforms
Reference
---------

.. autoclass:: toga.interface.font.Font
.. autoclass:: toga.font.Font
:members:
:undoc-members:
:inherited-members:
2 changes: 1 addition & 1 deletion docs/reference/widgets/imageview.rst
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ Supported Platforms
Reference
---------

.. autoclass:: toga.interface.widgets.imageview.ImageView
.. autoclass:: toga.widgets.imageview.ImageView
:members:
:undoc-members:
:inherited-members:
2 changes: 1 addition & 1 deletion docs/reference/widgets/label.rst
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Supported Platforms
Reference
---------

.. autoclass:: toga.interface.widgets.label.Label
.. autoclass:: toga.widgets.label.Label
:members:
:undoc-members:
:inherited-members:
2 changes: 1 addition & 1 deletion docs/reference/widgets/multilinetextinput.rst
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ Supported Platforms
Reference
---------

.. autoclass:: toga.interface.widgets.multilinetextinput.MultilineTextInput
.. autoclass:: toga.widgets.multilinetextinput.MultilineTextInput
:members:
:undoc-members:
:inherited-members:
2 changes: 1 addition & 1 deletion docs/reference/widgets/numberinput.rst
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Supported Platforms
Reference
---------

.. autoclass:: toga.interface.widgets.numberinput.NumberInput
.. autoclass:: toga.widgets.numberinput.NumberInput
:members:
:undoc-members:
:inherited-members:
2 changes: 1 addition & 1 deletion docs/reference/widgets/optioncontainer.rst
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ Supported Platforms
Reference
---------

.. autoclass:: toga.interface.widgets.optioncontainer.OptionContainer
.. autoclass:: toga.widgets.optioncontainer.OptionContainer
:members:
:undoc-members:
:inherited-members:
2 changes: 1 addition & 1 deletion docs/reference/widgets/progressbar.rst
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Supported Platforms
Reference
---------

.. autoclass:: toga.interface.widgets.progressbar.ProgressBar
.. autoclass:: toga.widgets.progressbar.ProgressBar
:members:
:undoc-members:
:inherited-members:
2 changes: 1 addition & 1 deletion docs/reference/widgets/scrollcontainer.rst
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ Supported Platforms
Reference
---------

.. autoclass:: toga.interface.widgets.scrollcontainer.ScrollContainer
.. autoclass:: toga.widgets.scrollcontainer.ScrollContainer
:members:
:undoc-members:
:inherited-members:
2 changes: 1 addition & 1 deletion docs/reference/widgets/selection.rst
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Supported Platforms
Reference
---------

.. autoclass:: toga.interface.widgets.selection.Selection
.. autoclass:: toga.widgets.selection.Selection
:members:
:undoc-members:
:inherited-members:
2 changes: 1 addition & 1 deletion docs/reference/widgets/splitcontainer.rst
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ Supported Platforms
Reference
---------

.. autoclass:: toga.interface.widgets.splitcontainer.SplitContainer
.. autoclass:: toga.widgets.splitcontainer.SplitContainer
:members:
:undoc-members:
:inherited-members:
2 changes: 1 addition & 1 deletion docs/reference/widgets/table.rst
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ Supported Platforms
Reference
---------

.. autoclass:: toga.interface.widgets.table.Table
.. autoclass:: toga.widgets.table.Table
:members:
:undoc-members:
:inherited-members:
2 changes: 1 addition & 1 deletion docs/reference/widgets/textinput.rst
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ Supported Platforms
Reference
---------

.. autoclass:: toga.interface.widgets.textinput.TextInput
.. autoclass:: toga.widgets.textinput.TextInput
:members:
:undoc-members:
:inherited-members:
2 changes: 1 addition & 1 deletion docs/reference/widgets/tree.rst
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ Supported Platforms
Reference
---------

.. autoclass:: toga.interface.widgets.tree.Tree
.. autoclass:: toga.widgets.tree.Tree
:members:
:undoc-members:
:inherited-members:
2 changes: 1 addition & 1 deletion docs/reference/widgets/webview.rst
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Supported Platforms
Reference
---------

.. autoclass:: toga.interface.widgets.webview.WebView
.. autoclass:: toga.widgets.webview.WebView
:members:
:undoc-members:
:inherited-members:
2 changes: 1 addition & 1 deletion docs/reference/widgets/widget.rst
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ The widget class is a base class for all widgets and not designed to be instanti
Reference
---------

.. autoclass:: toga.interface.widgets.base.Widget
.. autoclass:: toga.widgets.base.Widget
:members:
:undoc-members:
:inherited-members:
Loading

0 comments on commit fb3702e

Please sign in to comment.