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
BoxLayout: | |
NavBar: | |
sm: screen_manager | |
ScreenManager: | |
id: screen_manager |
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
import kivy | |
kivy.require('1.8.1') | |
from kivy.app import App | |
from kivy.lang import Builder | |
root = Builder.load_string(''' | |
FloatLayout: | |
Widget: | |
pos_hint: {'center_x': 0.5, 'center_y': 0.5} |
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 property_handler(self, inst, value): | |
try: | |
widget = self.ids.widget_id | |
except AttributeError: | |
Clock.schedule_once(lambda dt: self.property_handler(inst, value)) | |
else: | |
widget.some_value = value |
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
import kivy | |
kivy.require('1.9.1') | |
from kivy.app import App | |
from kivy.lang import Builder | |
from kivy.properties import StringProperty | |
from os.path import join, dirname | |
root = ''' | |
Button: |
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
<AppDialog>: | |
size_hint: 1, None | |
height: grid.minimum_height | |
GridLayout: | |
id: grid | |
size_hint_x: 0.8 | |
size_hint_y: None | |
height: self.minimum_height | |
on_height: root._align_center() |
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 twisted.internet.protocol import Protocol, ClientFactory | |
from twisted.internet.defer import inlineCallbacks | |
from twisted.internet.threads import deferToThread | |
import pdb | |
# audio imports | |
import pyaudio,wave | |
class AudioClientFactory(ClientFactory): | |
def __init__(self, canvas_obj): | |
self.canvas_obj = canvas_obj |
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
import kivy | |
kivy.require('1.8.1') | |
from kivy.app import App | |
from kivy.lang import Builder | |
from kivy.properties import DictProperty | |
from kivy.clock import Clock | |
from random import random | |
root = ''' |
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
<Separator@Widget>: | |
canvas: | |
Color: | |
rgba: 1, 1, 1, 1 | |
Rectangle: | |
pos: self.pos | |
size: self.size | |
<HSeparator@Separator>: | |
size_hint_y: None |
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
#import <Foundation/Foundation.h> | |
#import <CoreBluetooth/CoreBluetooth.h> | |
@interface cbcentral : NSObject<CBCentralManagerDelegate> { | |
CBCentralManager* central; | |
NSMutableArray* events; | |
NSLock* eventlock; | |
NSMutableArray* _peripherals; | |
CBPeripheral* _connecting; | |
} |
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
import kivy | |
kivy.require('1.8.1') | |
from kivy.app import App | |
from kivy.lang import Builder | |
from kivy.clock import Clock | |
from kivy.utils import interpolate | |
from time import time | |
root = Builder.load_string(''' |
NewerOlder