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
__author__ = 'Alan' | |
__version__ = '0.1' | |
import kivy | |
kivy.require("1.0.0") | |
from kivy.app import Builder | |
from kivy.app import App | |
from kivy.uix.gridlayout import GridLayout | |
from kivy.uix.scrollview import ScrollView |
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
__author__ = 'Alan' | |
__version__ = '0.1' | |
import kivy | |
kivy.require("1.0.0") | |
from kivy.app import Builder | |
from kivy.app import App | |
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.uix.gridlayout import GridLayout | |
from kivy.uix.label import Label | |
from kivy.uix.image import Image | |
from kivy.app import Builder, App | |
from random import randint | |
Builder.load_string(""" | |
<GridLayout>: |
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.gridlayout import GridLayout | |
from kivy.uix.label import Label | |
from kivy.uix.image import Image | |
from kivy.app import Builder, App | |
from random import randint | |
from kivy.uix.stacklayout import StackLayout | |
from pygments.formatters import img | |
Builder.load_string(""" |
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.label import Label | |
from kivy.uix.image import Image | |
from kivy.uix.stacklayout import StackLayout | |
from kivy.app import Builder, App | |
class MyApp(App): | |
def build(self): | |
lay1 = StackLayout(size_hint_y=None) | |
lay1.bind(minimum_height = lay1.setter("height")) |
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.label import Label | |
from kivy.uix.image import Image | |
from kivy.uix.stacklayout import StackLayout | |
from kivy.app import Builder, App | |
class MyApp(App): | |
def build(self): | |
lay1 = StackLayout(size_hint_y=None) | |
lay1.bind(minimum_height = lay1.setter("height")) |
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
class MyClass(object): | |
def method_a(self, **kwargs): | |
self.method_b('arg_x_value', **kwargs) | |
def method_b(self, arg_x, arg_y=None, **kwargs): | |
print arg_y | |
self.method_c(**kwargs) | |
def method_c(self, arg_z=None): | |
print arg_z |
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
class Base(object): | |
def methodX(self): | |
print "methodX from Base" | |
def methodY(self): | |
print "methodY from Base" | |
class BaseDeriv(Base): #inherits methodX | |
def methodY(self): #overrides methodY | |
print "methodY BaseDeriv Override" |
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.app import Builder | |
from kivy.uix.stacklayout import StackLayout | |
from kivy.uix.button import Button | |
from kivy.properties import NumericProperty | |
Builder.load_string(""" | |
<Button>: | |
size_hint: None, None | |
size: app.my_unit, app.my_unit*0.4 |
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
using System; | |
class PackingBits | |
{ | |
static void Main(string[] args) | |
{ | |
// say you have this data: | |
byte byteA = 7; | |
byte byteB = 5; | |
ushort someNumber = 1500; |
OlderNewer