Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - billarhos

Pages: [1] 2
1
General Discussion / About TGUI 0.9-dev
« on: 19 May 2019, 08:46:14 »
Hi Texus. Read in facebook about TGUI 0.9-dev and batching rendering. This is awsome!

In your post:
Quote
In release mode, TGUI 0.8 takes 0.25 seconds to render it while TGUI 0.9-dev reduces this to just 0.08 seconds (on a laptop with intel graphics).

One quarter of a second is too much time to render those few widgets. May be you meaning milliseconds? I have never seen those times in all past and current tgui versions.

Will tgui 0.9 continue to work as it is now? Will this be configurable, meaning select the way tgui renders?

What happens in future if tgui texts have outline color?




2
Help requests / "ReturnKeyPressed" Signal on textbox widget
« on: 01 March 2019, 08:42:03 »
Code: [Select]
pTextBox->connect("ReturnKeyPressed", [&]()
{

});

pTextBox->connect("ReturnKeyPressed", pressedFunc, pTextBox);

both above declarations are giving me an exception.

Quote
Exception thrown at 0x743B18A2 in Tgui.exe: Microsoft C++ exception: tgui::Exception at memory location 0x0113EA68.
Unhandled exception at 0x743B18A2 in Tgui.exe: Microsoft C++ exception: tgui::Exception at memory location 0x0113EA68.

in
Quote
unsigned int SignalWidgetBase::connect(std::string signalName, Func&& handler, const Args&... args)

I am using the day before yesterday's patch. (before "right click" in listview fixed)

Missing something?



3
Feature requests / listview and add item
« on: 24 February 2019, 16:03:52 »
Hi Texus

You have:
Code: [Select]
1 : std::size_t addItem(const sf::String& text);
2: std::size_t addItem(const std::vector<sf::String>& item);
3 : bool removeItem(std::size_t index);

4 : void setSelectedItem(std::size_t index);
5: int getSelectedItemIndex() const;
i am sure that i forget some other functions

1. Add item as a row or in a specific cell in a specific column
Code: [Select]
std::size_t addItem(std::size_t columnIndex, const sf::String& text);

2: should be
Code: [Select]
std::size_t addRow(const std::vector<sf::String>& item);

3. is remove item - or remove row
4. setSelectedItem on which column
5. is selected row or selected a specific cell in a specific column
 
there is a need to be distiguish the cell index and the column index.
Also there is need for a "setCell(column, cell, text)" function like :
Code: [Select]
void setColumnText(std::size_t index, const sf::String& text);

and may be a

Code: [Select]
std::size_t addMultiRows(const std::vector<std::vector<sf::String>> & item);

thank you



4
Help requests / List view
« on: 30 January 2019, 17:23:16 »
Hi Texus. I 've Just download 8.3 version and implemented a listview widget replacing a listbox thinking of make better look.

When you add a column also a vertical border line appearing just to show the different column. However you must add a vertical border only in between two columns and not after it.

When there is one column should not be added this vertical border. If two columns exist the one vertical border should be in the middle of two columns. And so on

vertical borders = columns  > 0 ? columns -1 : 0



5
Help requests / ChildWindow change position when title changes.
« on: 14 January 2019, 17:57:42 »
Hi

When i change the title of a child window the windows moves a bit inside the main (windows) form. I change title text because i am using more than one language.
This happening when height of child window is smaller than main window (570). However if the child window has the same height with form (600px) the the title tongle between visible and invisible.

Using github version

Code: [Select]
mWindow.create(sf::VideoMode(800, 600), "Sfml + Tgui example", style, contextSettings);
mWindow.setFramerateLimit(60);
mGui.setTarget(mWindow);


tgui::ChildWindow::Ptr pWindow = tgui::ChildWindow::create();
pWindow->setSize(800, 570);
pWindow->setPosition(0, 0);
pWindow->setKeepInParent(true);
pWindow->setTitleAlignment(tgui::ChildWindow::TitleAlignment::Center);
pWindow->getRenderer()->setTitleBarHeight(22);
pWindow->setTitle("Bill");

//-----------------------------------------------------------------------
pButtonLoad = tgui::Button::create();
pButtonLoad->setSize(150, 50);
pButtonLoad->setPosition(800 / 2 + 50, 600 / 2 - 20);
pButtonLoad->getRenderer()->setTextColor(sf::Color::Black);
pButtonLoad->setText("Load");
pButtonLoad->connect("MousePressed", [=]()
{
pWindow->setTitle("Billarhos");
});

6
Feature requests / "opacity when widget is disabled
« on: 10 January 2019, 12:23:25 »
Hi Texus. Happy new year.

Good news. I started using 0.8.2.  I finished one of my big projects. I done all the changes and now i am changing the little details in order all widgets looks like before.
Thank you for the great work you done.

I was thinking if a "opacity when widget is disabled" property in all widgets can be added. Right now, when i want for instance a check box to be disabled i set the manually the opacity to 0.3. So the user can easily understand that this widget can not be touched-changed. Ii should be great if we can have this out of the box!

Also, if i run "setOpacity" other than 1.0f before adding widget to gui manager the opacity does not apply. It works if i first add the widget and then apply new opacity. I tried this with "button".

cheers


7
Feature requests / Checkbox future improvments
« on: 30 December 2018, 12:29:32 »
Hi,
I am trying to set initial value to checkbox without sending to me back a signal event. This is happening on initializing. It is important for me this two callbacks not to be triggered
in initializing progress. Only to set the visible part of checkbox (On/Off).

Now it is ok because i am using some booleans to avoid this.

This can be prevented by adding a "SetState(bool onOff)" function without triggering any callbacks in it.

Code: [Select]
pCheckBox = GAME_MANAGER->getGuiTheme()->load("CheckBox");
pCheckBox->setPosition(GAME_MANAGER->layoutWidth(450), GAME_MANAGER->layoutHeight(280));
pCheckBox->setSize(GAME_MANAGER->layoutWidth(100), GAME_MANAGER->layoutHeight(50));

pCheckBox->connect("Checked", [=]()
{
//do something here but only when user check this
});

pCheckBox->connect("Unchecked", [=]()
{
//do something here but only when user uncheck this
});

if (MEMORY_MANAGER->readDataBool(MemoryMain::checkBoxStatus))
pCheckBox->check();
else
pCheckBox->uncheck();



Also a general callback with the name "changed"  it would be a good idea.

thank you


8
Feature requests / Clickable textbox
« on: 19 December 2018, 19:44:34 »
Hi.
Using a textbox widget to display some info text, i came in front of two obstacles.

1.Even using "setReadOnly" function, in "editbox" you can still select some words or lines.
2.I was unable to find a way to catch a mouse left click on "editbox", in order to close my help form.

I am using 0.7.5 version.

thanks for reading

9
Feature requests / center align in labels
« on: 12 May 2018, 11:06:25 »
Hi Texus.

The center alignment when more than one lines exist, in my case in "buttons" but i can think that the same happening in "labels" also since "buttons" uses "labels", has not
correct align. All lines keep the first line start position. But each line has different count of chars.

It would be great if this would be implement at least in the new version of tgui. This, it would give me an extra motivation to start using 0.8 version sooner ;)

cheers


10
Help requests / click on buttons when the view is changed
« on: 29 March 2018, 21:54:40 »
Hi,
i found a strange bug. Really can not say if this is sfml or tgui problem but is is happening on button widjets when changing size and view on sfml form
along with changing the alpha color of form.

here is the repro project
http://www.mediafire.com/file/d2nadgdqb9wstw9/Tgui.rar

Code: [Select]
sf::Uint8 alpha = 80;
HWND hwnd = mWindow.getSystemHandle();
SetWindowLongPtr(hwnd, GWL_EXSTYLE, (GetWindowLongPtr(hwnd, GWL_EXSTYLE) | WS_OVERLAPPEDWINDOW) | WS_EX_LAYERED);
SetLayeredWindowAttributes(hwnd, 0, alpha, LWA_ALPHA);

if i use the above lines then when i hit the left button the signal goes to the right button and vice versa. Strange, isn't it?
Hope Texus u come with any idea.

thanks






11
Help requests / canvas widget on windows 7
« on: 15 March 2018, 07:57:24 »
Hi.

Well this time it is a crush. I installed my app to windows 7, 64 and after some tests i realized that canvas widget causing the problem. I removed it and the app stop crushing.
I am using a lot of different widgets but only this causing the problem. I have install a lot of versions of vga drivers and the problem remains. Maybe there is some version that stops the problem. Of cource, the crushing happening only on win 7 64 and not on windows 10, 64.
The code snippet shows when the crush occurs. (on destroy)

Code: [Select]

//cpp
//-----------------------------------------------------------------------------
cForm::cForm() :
{
sf::RectangleShape line(sf::Vector2f(1, 800));
line.setFillColor(sf::Color::Black);
line.setPosition(sf::Vector2f(0, 1));

pCanvas = tgui::Canvas::create({ 10, 800 });
pCanvas->setPosition(330, 70);
pCanvas->clear(sf::Color(194, 206, 200));
pCanvas->draw(line);
pCanvas->display();

GAME_MANAGER->getGui()->add(pCanvas);
}

cForm::~cForm()
{
GAME_MANAGER->getGui()->removeAllWidgets();
       //-->the crash problem
}
//h
//-----------------------------------------------------------------------------
class cForm
{
public:
cForm::cForm();
~cForm();
private:
tgui::Canvas::Ptr pCanvas;
}

Any clue mates?




12
Feature requests / Upside down slider issue
« on: 18 January 2018, 16:18:54 »
Hi Texus.

I am trying to make a sound equalizer with vertical sliders to adjust low, mid , high frequencies.
However there is no way to set positive number to up and negatives to down side of sliders.

pSliderEqMid->setMinimum(-20);
pSliderEqMid->setMaximum(20);

Photo shows better what i try to achive.

Also, it would be great, to have a step value for slider (i know is a mess).





13
Feature requests / spin have some issues.
« on: 10 January 2018, 16:37:03 »
Hello Texus

I tried "spinbutton" but setBackgroundColor,  setBackgroundColorNormal,  setBackgroundColorHover not working nor from txt file, neither from code.

Also, what is the difference between setBackgroundColor and setBackgroundColorNormal?

Suggestions: It would be great if a step value exist. Also, a text shown with the current value in between buttons as optional would be great!

thank you.


14
Help requests / Grid issue
« on: 27 July 2017, 16:38:12 »
Hi.
When i add some buttons to my grid widget, i use the center align (default).
However if i use removeAllWidgets before i add my buttons to grid the alignment is getting top-left.

I use the 0.7.4

Code: [Select]
pGrid->removeAllWidgets();

int index = 0;
for (unsigned int row = 0; row < 2; ++row)
for (unsigned int col = 0; col < 2; ++col) {
pGrid->addWidget(pGridButtons[index++], row, col);

One solution is to use this code insted of "removeAllWidgets()"
Code: [Select]
auto& widgets = pGrid->getWidgets();
for (int i = 0; i < widgets.size(); i++)
{
pGrid->remove(widgets[i]);
}

15
General Discussion / Shortcut ctrl+c hangs my programm (editBox)
« on: 09 March 2016, 15:28:54 »
Hi

When press ctrl+c, in all cases (empty edibox, edibox with text, editbox with text selected) i got exception error.
Happens in debug and release.
Are shortcuts supported by editbox?

Using Visual studio 2013
thanks

Pages: [1] 2