Mixins that adds margin functionality to Kivy widgets
Project description
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 https://github.com/AndreMiras/garden.layoutmargin/archive/develop.zip
Credits
Forked from Enteleform/-Kivy-MarginLayout-Demo.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
layoutmargin-0.0.0.tar.gz
(3.3 kB
view details)
Built Distribution
File details
Details for the file layoutmargin-0.0.0.tar.gz
.
File metadata
- Download URL: layoutmargin-0.0.0.tar.gz
- Upload date:
- Size: 3.3 kB
- Tags: Source
- Uploaded using 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
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 48afb2ee52fd222b7a3d0ec48791c4157fefc8dac1fab9f56437402ec38df463 |
|
MD5 | dfa8b0b880833e8b2773bc4ae620f950 |
|
BLAKE2b-256 | 5034fff80fd006d012a63358c440f899012b47d59be3b24eb6e350d7c129e242 |
File details
Details for the file layoutmargin-0.0.0-py3-none-any.whl
.
File metadata
- Download URL: layoutmargin-0.0.0-py3-none-any.whl
- Upload date:
- Size: 4.6 kB
- Tags: Python 3
- Uploaded using 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
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | c23c234d70d13e2076d3ea61aabbfbac0bd6fbe9c710587b168edda471557c23 |
|
MD5 | 7acb0eda3e0de9b88ee60152384fd218 |
|
BLAKE2b-256 | e474403b64aec4ae445e95cff0abdb55650b1821553cbce1dd882ef80009da65 |