[Extension] Advanced - Decoration Components Extension

You can customize any component with this extension.

Onlick returns ~(Component component, Integer id)
OnLongClick returns ~(Component component, Integer id)
OnTouch returns ~(Component component, String event, Integer x, Integer y)

Decoration

component: any component
radius: “topleft,topright,bottomleft,bottomright”
colorBg: Integer or Kodular Color
strokeWidth: Integer
strokeColor: Integer or Kodular Color

Set Elevation

component: Component
elevation: Integer

Set Padding

component: Component
left: Integer
top: Integer
right: Integer
bottom: Integer

Set Margin

component: Component
left: Integer
top: Integer
right: Integer
bottom: Integer

Set Clickable

component: Component
enable: Boolean

Set On Touch Listener

component: Component
enable: Boolean

Download AIX:
com.ruwis.decoration.aix (12.8 KB)

Download Example AIA:
Decoration.aia (75.7 KB)

21 Likes

Nice extension :clap:

A question, can I put a photo in an arrangement and still leave it with rounded corners?

2 Likes

You don’t have to use layout. It could also be a image.

1 Like

@OmerGundogar You should rename your Decoration.SetTouchOnListener to Decoration.SetOnTouchListener.
BTW, nice work !

2 Likes

thank you very much my dear pal for such nice extension…

LOVE U FROM KURDISTAN :heart::heart_decoration::yellow_heart::heart_decoration::green_heart:

1 Like

fixed thanks :slight_smile:

2 Likes

Whenever i import kodular inbuilt decoration component blocks are broke

1 Like

This is because the extension class name is same decoration component. That’s why it breaks the inbuilt decoration component.
@OmerGundogar should rename the extension name to something different. It happened to me with my list view extension then I renamed it.

3 Likes

The extension is probably conflicting with the inbuilt decoration component.

1 Like

Small bug in Set Padding Block.
Parameter “top” defines Right
Parameter “right” defines Top

decoration - padding

3 Likes

I updated the link above. If you download it, there will be no such problem.

I tried it yesterday. If i have the kodular decoration component and i add your extension it gets in conflict cause of the same name. But it works perfectly anyway. Thx for your work.

1 Like

Can we not make a border in a table arrangement same like a grid?

why clickable not working see

Have you set clickable to true for those components using call decoration.SetClicable block ?

yes

Just tested it with two components and it works for me. Since I can not see your design I can not tell why it doesn’t work for you

why not working when i m enabling ease card in arrangment?

This is an excellent extension, thanks so much for making it available :grinning:
I just have the unfortunate conflict with the extension name being ‘Decoration’, because I have a big project that already uses the Kodular default Decoration component with hundreds of blocks (can’t change that now), so it breaks my project when I import it.

1 Like

Before importing extension try to rename Decoration component to Decor for example from designers’s view. That should automatically change also the name in blocks. After that import extension. Make sure to backup your project, just in case something goes wrong

image

2 Likes