In this video I’ll show you how to create rounded buttons with Kivy.

Rounded buttons are actually pretty easy to make with Kivy. We’ll just use the Canvas and create a roundedrectangle that we define with the color and radius that we want.

It’s pretty straight forward!

Python Code:
GitHub Code:

from import App
from kivy.uix.widget import Widget
from kivy.lang import Builder
from kivy.core.window import Window

# Designate Our .kv design file 

class MyLayout(Widget):

class AwesomeApp(App):
	def build(self):
		Window.clearcolor = (1,1,1,1)
		return MyLayout()

if __name__ == '__main__':

Kivy Design Code: round_buttons.kv
GitHub Code: round_buttons.kv


		orientation: "vertical"
		size: root.width, root.height

		padding: 50
		spacing: 20

			text: "Hello World!"

			text: "Goodbye World!"
			pos_hint: {'center_x': 0.5}
			size_hint: (1, .3)
			#background_color: (48/255,84/255,150/255,1)
			#background_normal: ''
			on_press: print("Goodbye!")

<[email protected]>
	background_color: (0,0,0,0)
	background_normal: ''
			rgba: (48/255,84/255,150/255,1)
			size: self.size
			pos: self.pos
			radius: [58]

John Elder

John is the CEO of where he teaches over 100,000 students how to code! He founded one of the Internet's earliest advertising networks and sold it to a publicly company at the height of the first dot com boom. After that he developed the award-winning Submission-Spider search engine submission software that's been used by over 3 million individuals, businesses, and governments in over 42 countries. He's written several Amazon #1 best selling books on coding, and runs a popular Youtube coding channel.

View all posts

Add comment

Your email address will not be published. Required fields are marked *

John Elder