garden.layoutmargin
A set of mixins (MarginLayout, AddMargin) that adds margin functionality to Kivy widgets.
How to use
@ .py subclasses:
from layoutmargin import AddMargin, MarginLayout
class MarginBoxLayout(MarginLayout, BoxLayout):
pass
class MarginButton(AddMargin, Button):
pass
@ .kv layout:
MarginBoxLayout:
MarginButton:
margin: (30, 10, 30, 10) # integer / float
MarginButton:
margin: ("10%", "10%", "10%", "10%") # percentage of total widget size
MarginButton:
margin: (30, "10%", 30, "10%") # mixed
Run the demo
make run
Install
pip install layoutmargin
Credits
Forked from Enteleform/-Kivy-MarginLayout-Demo.
Metadata
Release files for layoutmargin 20190911
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| layoutmargin-20190911.tar.gz | 3.3 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| layoutmargin-20190911-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 8.0 kB
Release files / layoutmargin-20190911.tar.gz
| Download URL | layoutmargin-20190911.tar.gz |
|---|---|
| Size | 3.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
0643b03abe01fb51f89c757e4ea1a354e77920fa6cd60816acb4466c7284362f
|
|
BLAKE2b-256 checksum How to use checksums |
cd027a75743f5bf4356d5c26cad861ad7da30f02d7c7d2c9c2a22d4501725f7c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.8
|
Release files / layoutmargin-20190911-py3-none-any.whl
| Download URL | layoutmargin-20190911-py3-none-any.whl |
|---|---|
| Size | 4.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
9ff709ad5728316dbe51638022a1e09a0f924a0615dd3cd326211e02d9033373
|
|
BLAKE2b-256 checksum How to use checksums |
021bc046b09c063ee9773039661159fe3a843e1ca68f6f274866362301311f18
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.8
|