How to make the corners of my border image rounder in kivy

Stack Overflow Asked on January 3, 2022

        self.kk = Button(text='pushme', size_hint=(0.15,0.15), background_color =[0,0,0,1])
        with self.kk.canvas.before:
            size=(self.kk.width + 20 , self.kk.height-7 ),
            pos=(self.kk.x  , self.kk.y),
            border=(50, 50, 50, 50),

I want to make the border image rounder so i added ‘border’ as I though this would work i increased and decreased the number but no difference, if possible could give me the answer in python language

One Answer

I don't think there's any straightforward way to round the corners of a BorderImage, except by rounding the corners of the image it is displaying. That should actually be quite easy, so it's the most obvious option.

Within Kivy, you can use a RoundedRectangle canvas instruction, but then you can't use the normal button background properties (or must manually bind them to control the shape of that new instruction).

Answered by inclement on January 3, 2022

Add your own answers!

Related Questions

Braintree payment form not working | Django

4  Asked on January 5, 2022 by felipe-dourado


a more general version of `ifelse` in R?

4  Asked on January 3, 2022 by indrajeet-patil


Pandas sorting data in a dataframe with multiple headers

1  Asked on January 3, 2022 by sophia-deng


How to merge same Ids data with mysql?

1  Asked on January 3, 2022


sum for id’sin python

4  Asked on January 3, 2022 by maddy6


How to synchronously change state within useState

2  Asked on January 3, 2022 by michael-gee


‘List’ is not a subtype of type ‘Map’

2  Asked on January 3, 2022 by uchenna-ndukwe


Javascript load Array from Text File

1  Asked on January 3, 2022 by crapcoder


Ask a Question

Get help from others!

© 2023 All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP