Questions tagged [kivy-language]

A language created and used in the Kivy framework to describe a widget structure of a project.

Kivy language (kv, kvlang) is a language created and used in the Kivy framework to describe a widget structure of a project.

The concept behind kv is to make maintaining mainly the design part of an application simple. Kv provides features that make building an application easy and readable in large projects:

With these features kv allows very fast prototyping and agile changes to User Interface. It also facilitates a good separation between the logic of an application and its UI, therefore provides possibilities to minimize code size and maximize readability.

For real-time debugging of the kv code you can use KivyCatalog.

2724 questions
3
votes
2 answers

Kivy window hide/show

I'm a newby with python programming and tought, to learn let me create a project. Here is what i'm trying to do. I want to create a program that runs in system tray and fire's a program that is loaded in the background. Loaded in the background so I…
Stalin
  • 31
  • 2
3
votes
2 answers

How do I change the background color of a button in Kivy?

I am attempting to build a simple app that plays music every time a click on a button that I built in kivy. I would like to add graphics and styling, as the default color is just plain grey. How do I do I change that color to red? I have tried…
Ajax1234
  • 69,937
  • 8
  • 61
  • 102
3
votes
1 answer

How do I move a Kivy widget's canvas items if the items are defined in .py and not kv lang?

I need to be able to spawn arbitrary "Planets" of various shapes, sizes, and colors, and move them around in a multi-body simulation, add them, and remove them as things happen in the simulation. I have added a number of operations to an instance of…
Mars
  • 195
  • 1
  • 10
3
votes
1 answer

python-kivy buildozer app works in pc but not in android

I'm newbie in coding with python/kivy. I have a problem building an android app via kivy buildozer. First of all, if I build the app and I use kivy like this for example: self.asdbut = Button(text="xxxxxx",…
3
votes
2 answers

Can't use transitions in kv lang

App code: from kivy.app import App from kivy.lang import Builder from kivy.factory import Factory from kivy.uix.screenmanager import Screen from kivy.uix.screenmanager import ScreenManager from kivy.uix.screenmanager import FadeTransition
kv =…
3
votes
3 answers

Kivy's ScreenManager and Popups don't want to work together

as stated in the title - I'm stuck. I've been playing with the code around and everything works as long as I keep ScreenManager and Popup separate. Once combined - they refuse to cooperate. Anyway, here is the simple app that shows the problem I'm…
Taporp
  • 78
  • 1
  • 7
3
votes
1 answer

Retrieving MySQL with Kivy

I have a Kivy code, where the output is: I want to get replace the Box No. with strings retrieved from MySQL So far I have tried to implement the MySQL to the python script: class RemoveScreen(MyLayout): def __init__(self,**kwargs): …
3kstc
  • 1,871
  • 3
  • 29
  • 53
3
votes
2 answers

KIVY language: multiple commands in a single line

I have to do: TextInput: on_text: something ; something_else How can I perform this without getting errors in kv language?
mattogol
  • 33
  • 3
3
votes
1 answer

import widget in kivy file

I created some custom widget. from kivy.uix.widget import Widget from kivy.lang import Builder class ExampleWidget(Widget): Builder.load_file("kv/example.kv") kv/example.kv #:kivy 1.9.1 : Label: text:…
Dima Kudosh
  • 7,126
  • 4
  • 36
  • 46
3
votes
2 answers

How to change a space when a button is pressed with kivy?

I am trying create a GUI by implementing the template of the ComicCreator GUI sample as a template for my own project. The code is easy to follow, but I would like to be able to reconfigure the drawingspace.kv, each time a button is pushed, say for…
3kstc
  • 1,871
  • 3
  • 29
  • 53
3
votes
0 answers

Highlight a Kivy ToggleButton with mouse hovering

I am currently coding a GUI with Kivy. I need to modify a ToggleButton behaviour so that it is highlighted when hovered by the mouse. Here is my code so far: class FilterToggle(ToggleButton): def __init__(self, **kwargs): …
Lo Bellin
  • 485
  • 4
  • 20
3
votes
3 answers

Kivy kv file is not working

I have the same issue like described in this theme kv incorrect. When I use Builder and load the kv file I have normal working app. But when I try to use autoload kv file I have only black screen. Could someone explain me why? Thanks for any…
Velidan
  • 5,526
  • 10
  • 48
  • 86
3
votes
1 answer

Break Line in a Kivy Label doesn't work (Python)

I'm trying to add a Label to python through the kivy app module and the break line doesn't work. I don't know why, because I've read that actually had to run perfectly. The text in kv language is: Label: text: 'hola hola hola hola…
A.Piquer
  • 414
  • 9
  • 23
3
votes
1 answer

WARNING: Ignored class "Label" re-declaration

In order to make all labels' text support markup I use the following kivy-language code at the top of my kivy file: : markup: True Later on when using: : Label: text: '[b]Dog[/b]' I get a label with the…
user
  • 5,370
  • 8
  • 47
  • 75
2
votes
0 answers

Android app coded in python crashes after splashscreen and logcat gives errors

I coded an Android app in Python with the kivy library and compiled it with buildozer. When I opened it on an Android phone, it crashes after the splashscreen. This is the logcat error. What is the issue? 2023-05-08 19:40:29.663 12397-12431 bt_btif …