Recent Posts

Pages: 1 ... 8 9 [10]
91
General Discussion / Re: Buttons 0.9
« Last post by texus on 08 June 2019, 11:52:31 »
Quote
Yesterday is saw default argument in "ignoreMouseEvents" (picture). Ok, why setEnabled or setVisible on the other hand don't have.
Because setEnabled and setVisible are equally likely to be called with true or false while you would only call ignoreMouseEvents with true (as false is the default and you typically don't toggle that property). That being said, I know that some function have default arguments while others don't where I can't make such a clear distinction. The problem is that I don't really like the default arguments as I feel like people might incorrectly see them as an indication of what the default is when the function isn't called and the default parameter value is usually the exact opposite of the default value used by the widget. So in more recent additions I didn't add a default argument at all.

Quote
Instead of rewriting the whole project why don't you add the missing widgets.
Because widgets and extra functions can always be contributed by others, nobody other than me is going to change the architecture of the entire gui.
I also tend to work in 2 phases, during development of a new version I can change the API so I try to change as much as possible at once while after the API gets more stable again I can focus on adding functionality that doesn't break the API (such as adding new widgets). By spending too much time in the unstable phase I always end up dividing the community in 2 versions (those using the older stable version and those using the newest unstable version), so I don't want this phase to last longer than 1-2 years. So things that can be done after tha API gets stable tend to get delayed during early development of a new version.

Quote
There are a lot of tiny improvements that can be done. Like having all those "signalNames" for all widgets in one place!
This is hard to do with the inheritance. I'm also planning on a system like using the onSignal objects directly instead of using the signal names so it might get even more difficult to get things in one place.
92
General Discussion / Re: Buttons 0.9
« Last post by billarhos on 08 June 2019, 11:10:05 »
Quote
What exactly do you want to me to look at with that gui?
Nothing really. Just to take a look. I haven't used fairygui yet but i was looking for an alternative among other libraries if some project of mine wanted advance features for gui. In my programming years i have use wxWidgets, QT and dotnet. However the last years since i abandoned "MARMALADE" (in fact they abandoned us in first place) i am using sfml and tgui which tgui is great since i never had any problems.
 
Take a breath.
Batch rendering is great but after the performance boost in latest versions is not completely necessary.
Instead of rewriting the whole project why don't you add the missing widgets.
Yesterday is saw default argument in "ignoreMouseEvents" (picture). Ok, why setEnabled or setVisible on the other hand don't have.
There are a lot of tiny improvements that can be done. Like having all those "signalNames" for all widgets in one place!
I know the worm of perfection since i have one but life is also fun..






93
General Discussion / Re: Picture and OpacityDisabled
« Last post by billarhos on 07 June 2019, 14:23:21 »
You are correct. Is working. Really sorry. Investigating...
94
General Discussion / Re: Picture and OpacityDisabled
« Last post by billarhos on 07 June 2019, 14:04:11 »
Code: [Select]
picture = tgui::Picture::create(mFlagTextures[0]);
picture->setPosition(Settings::handler()->layoutWidth(flagXpos), Settings::handler()->layoutHeight(flagYpos));
picture->getRenderer()->setOpacityDisabled(0.3f);
picture->connect("MousePressed", [=]()
{
nextLang();
});

I ll try on a minimal code project...hold on.
95
General Discussion / Re: Picture and OpacityDisabled
« Last post by texus on 07 June 2019, 14:01:08 »
It seems to work for me. Could you share the code you are using (it may be related to the order things are executed)?
96
General Discussion / Picture and OpacityDisabled
« Last post by billarhos on 07 June 2019, 13:53:35 »
Setting OpacityDisabled for picture seems not working.
Code: [Select]
Picture {
OpacityDisabled = 0.3
}

However
Code: [Select]
picture->getRenderer()->setOpacityDisabled(0.3f); this is working.
97
General Discussion / Re: showWithEffect and hideWithEffect
« Last post by billarhos on 07 June 2019, 13:11:17 »
Thank you texus
98
General Discussion / Re: showWithEffect and hideWithEffect
« Last post by texus on 07 June 2019, 13:02:41 »
This should be fixed now.
99
Themes / Useful Resources
« Last post by rubenwardy on 07 June 2019, 02:56:19 »
Theming Superset Language

This is a Python script to make theming easier. Its main feature is to automatically build sprite sheets.

It has the following features:

  • It allows you to automatically build sprite sheets by looking in a source theme file for image names.
  • Texture = ${name}; will find the texture called name.png and then add it to the sprite sheet.
  • Texture = ${name:10}; will create a 9-slice with an inner padding of 10.
  • Texture = ${panel:10o+10}; will create a 9-slice with an inner padding of 10, but offset by 10 from the top (see the main body of the child window in the second screenshot).
  • Texture = ${titlebar:10o-10}; will create a 9-slice with an inner padding of 10, but offset by 10 from the bottom (see the main title of the child window in the second screenshot).
  • It allows you to import other theme files using #include "aaa.style".

https://github.com/rubenwardy/tgui-kenney




Example Form

This is a program to test themes, from the examples folder of texus/tgui

https://github.com/rubenwardy/tgui-example
100
General Discussion / Re: showWithEffect and hideWithEffect
« Last post by texus on 06 June 2019, 20:15:51 »
You are right, the value is indeed incorrectly reset. The code actually does reset the value to 255 by immediately finishing the show animation, but this happens just after the hide animation had already looked at the current alpha value.

I'll see if I can fix this tomorrow.
Pages: 1 ... 8 9 [10]