This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from kivy.app import App | |
from kivy.lang import Builder | |
from kivy.uix.screenmanager import ScreenManager, Screen | |
from kivy.uix.recycleview import RecycleView | |
class RvForScreen3(RecycleView): | |
def __init__(self, **kwargs): | |
super(RvForScreen3, self).__init__(**kwargs) | |
self.data = [{'text': str(x)} for x in range(10)] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from kivy.app import App | |
from kivy.lang import Builder | |
from kivy.uix.boxlayout import BoxLayout | |
from kivy.properties import NumericProperty | |
from kivy.network.urlrequest import UrlRequest | |
kv = """ | |
#:import itertools itertools | |
<Test>: | |
orientation: 'vertical' | |
RecycleView: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from random import sample, randint | |
from string import ascii_lowercase | |
from time import asctime | |
from kivy.app import App | |
from kivy.factory import Factory | |
from kivy.lang import Builder | |
from kivy.properties import NumericProperty, ListProperty | |
from kivy.clock import Clock |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from kivy.app import App | |
from kivy.lang import Builder | |
KV = ''' | |
#:import F kivy.factory.Factory | |
<MiniPopup@Popup>: | |
title: 'mini form!' | |
size_hint: None, None | |
size: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from kivy.app import App | |
from kivy.lang import Builder | |
from kivy.clock import Clock | |
from kivy.properties import ListProperty | |
from kivy.animation import Animation | |
KV = ''' | |
#:import RGBA kivy.utils.rgba | |
<ImageButton@ButtonBehavior+Image>: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# adapted from https://github.com/dpapathanasiou/pdfminer-layout-scanner | |
from os.path import exists | |
from tempfile import mkdtemp, mkstemp | |
from shutil import rmtree | |
from binascii import b2a_hex | |
from os import write, close | |
from threading import Thread | |
from pdfminer.pdfpage import PDFPage |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def _get_opacity(self): | |
if platform == 'win': | |
try: | |
return winxpgui.GetLayeredWindowAttributes(HWND)[1] / 255. | |
except Exception as e: | |
Logger.error( | |
'failed to get opacity: {}'.format(e)) | |
else: | |
Logger.warning( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from kivy.app import App | |
from kivy.animation import Animation | |
from kivy.lang import Builder | |
from kivy.properties import NumericProperty | |
from kivy.core.window import Window | |
from kivy.uix.boxlayout import BoxLayout | |
KV = ''' | |
FloatLayout: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from kivy.lang import Builder | |
from kivy.app import App | |
from kivy.uix.floatlayout import FloatLayout | |
from kivy.properties import ListProperty | |
from kivy.animation import Animation | |
KV = ''' | |
#:import C kivy.utils.get_color_from_hex |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from kivy.uix.widget import Widget | |
from kivy.lang import Builder | |
from kivy.base import runTouchApp | |
from kivy.properties import ListProperty, StringProperty | |
from kivy.vector import Vector | |
KV = ''' | |
#:import C kivy.utils.get_color_from_hex | |
#:import R kivy.resources.resource_find |