kivy-language

How can I define kivy dropodown list max height according to the screen height?

风流意气都作罢 提交于 2019-12-11 16:00:14
问题 I've created a DropDown list and dont want it to go all over the screen. So I tried to set the max_height value but i can only put absolute values. Instead, I want it to resize with the screen like I do with size_hint. I also tried to pass it in kv lang. Creating a DropDown class and setting max_height as (root.height -20), buit it doesnt work as it try to get the height of the DropDown class and not the Screen. Here is my code: from kivy.app import App from kivy.uix.screenmanager import

Retrieve image from sqlite3 and display in Kivy image widget - ValueError

♀尐吖头ヾ 提交于 2019-12-11 15:18:47
问题 REQUIREMENT I'm trying to retrieve an image from Database and set this image to kivy image widget, this operation throws a ValueError, unsure of the cause. Welcome any inputs. Database: Sqlite3 Table name: Users Columns: UserID, UserName, UserImage def populate_fields(self): # NEW # Code retrieves text data and display in textinput fields here. # STEP 1: RETRIEVE IMAGE connection = sqlite3.connect("demo.db") with connection: cursor = connection.cursor() cursor.execute("SELECT UserImage from

Kivy: How to get class Variables in Popup

谁说胖子不能爱 提交于 2019-12-11 14:52:08
问题 procedure: First you have to add a Name and than the Programm will set a Beginner (function "umdie()") after that the Screen "Wurfelbeginn" will Show you the names of the Players and the number which they had thorwn. After that you click on the Button "Wer beginnt?" to see who begins. And now my problem: i want to Showthe variable "Beginner" from the class Variablen in the popup, but if i call the variable nothing happens, but the console Shows the right names. What i am doing wrong? my main

Python : How to add row dynamic

≯℡__Kan透↙ 提交于 2019-12-11 14:14:34
问题 I am new to python/Kivy. I have two files test.py and test.ky. Now I am using two static row with serial number 1 and 2. Can anyone tell me? How to add row dynamic when click on '+add more' button.Now 2 row shows which are static row with serial number increment. I want add row dynamic 1 to 10 with serial number increment. test.py import kivy from kivy.uix.screenmanager import Screen from kivy.app import App from kivy.lang import Builder from kivy.core.window import Window Window.size = (450,

Kivy Making a Custom TreeViewNode

若如初见. 提交于 2019-12-11 11:06:32
问题 I'm attempting to create a custom TreeViewNode to use with a TreeView. Just want an image with a label next to it, nothing more. Yet attempting to create a custom node... even replicating how it's done in the source doesn't yield the same results. TreeViewlabel is literally just a class declaration with a comment in it class TreeViewLabel(Label, TreeViewNode): '''there's just a comment here''' This is my version of the TreeViewLabel for comparison class TreeViewImageLabel(Label, TreeViewNode)

How to make a file chooser in kivy to support files with different languages (English, Hebrew)

懵懂的女人 提交于 2019-12-11 10:27:34
问题 I am using kivy's file chooser and when there is a file of a folder with an Hebrew name, it prints gibberish... I want to support different languages if possible. Tried to change the font name in the file chooser, didn't work for me. Can you help me find out what am I doing wrong? 回答1: It's not only FileChooser - all instances of Label in Kivy use Roboto font as a default, which doesn't seem to support Unicode characters. Try running this code: from kivy.app import App from kivy.uix.label

Python Kivy Plots with MeshLinePlot confusion

本小妞迷上赌 提交于 2019-12-11 08:32:03
问题 I am trying to implement real time plots for measurements to a Kivy application, but I do not understand the inner workings of the kivy garden library. My goal that I want to achieve : I want to have multiple plots inside a ScrollView such that I can add multiple real time plots programmatically from a dictionary and scroll through them if they occupy more space than one screen height. The main problem I have is that the Graph does not behave like an ordinary Widget but rather behaves like a

Kivy Clock & Conditional Statements

天大地大妈咪最大 提交于 2019-12-11 07:58:20
问题 I created the variable timer_loop to run continuously. I'd like to make conditional statements with other variables, but I am unable to do so. Below is an example, I am trying to "do something" every 30 minutes if the switch is activated. Any feedback would be greatly appreciated :) from kivy.app import App from kivy.lang import Builder from kivy.clock import Clock import datetime import time theRoot = Builder.load_string(''' StackLayout: orientation: 'lr-tb' padding: 10 spacing: 5 Label:

Python Kivy Is Printing numbers while importing it

浪尽此生 提交于 2019-12-11 06:34:58
问题 I just installed Kivy in my virtualenv I installed it using pip install https://github.com/kivy/kivy/archive/master.zip My dependencies Python 2.7.10 Kivy==1.10.1.dev0 Cython==0.26.1 Kivy-Garden==0.1.4 When I tried to run it in my terminal using command from kivy.app import App Its printing integers recursively I have attached screenshot below Thanks in advance!! I Have Raised A GIT ISSUE ALSO :- https://github.com/kivy/kivy/issues/5515 回答1: I'll propose a workaround: it's to turn off

Why is my Kivy Actionbar gone?

独自空忆成欢 提交于 2019-12-11 06:17:05
问题 Good evening, I'm trying to combine kivy's actionbar with a screenmanager. I've gotten to the point where I can switch through screens, but am not able to get my actionbar to show. I've followed alot of examples, but none that can help me with my problem. I'm fairly new to kivy so I haven't been working with it for very long. I was kind of wondering if someone would be able to point out where my problem lies, because I'm trying to build my very own GUI with an action bar that lets me switch