Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: SFGUI (old thread)  (Read 85762 times)

0 Members and 1 Guest are viewing this topic.

Tank

  • SFML Team
  • Hero Member
  • *****
  • Posts: 1486
    • View Profile
    • Blog
    • Email
SFGUI (old thread)
« Reply #135 on: March 11, 2011, 01:06:28 am »
Try to set the "CXX" environment variable. Either it works by invoking it with scons (like "scons CXX=...") or specifying it in a custom SCons settings file (I setup the SFGUI SConscript so that it includes custom.py).

Are you sure that the used compiler in the project file is valid? The source file shouldn't be a problem, location looks correct.

Tank

  • SFML Team
  • Hero Member
  • *****
  • Posts: 1486
    • View Profile
    • Blog
    • Email
SFGUI (old thread)
« Reply #136 on: March 18, 2011, 08:26:23 pm »
A small nifty update. ;)

I just implemented a theme loader for the rendering engine. Themes basically consist of simple key/value pairs that influence the rendering engine's appearance. What properties are available depends on the used engine. The standard (and included) rendering engine "BREW" for example mostly takes colors and font sizes etc. (other engines might also load images or have effects)

I tried to separate the loading code as much as possible to hang in loaders for your custom format. I did a reference implementation for the YAML file format, however it won't make it into the master branch since it needs a dependency (yaml-cpp) that I want to avoid for public releases.

Instead, a very simple theme format will be introduced, that'll look as follows:
Code: [Select]

Button.Normal.BackgroundColor = #aabbcc
...


If you're interested in seeing the YAML loader, check out the "yaml" branch I uploaded to GitHub. How loading themes work can be seen in the sample application.

Always keep in mind that the whole stuff will get easier in the future. SFGUI will get a "workspace" class that includes the used rendering engine and methods for loading themes more easily.

Stay tuned for the basic theme file format loader. I'd appreciate any testing or comments, so feel free to drop a line here.

gsaurus

  • Sr. Member
  • ****
  • Posts: 262
    • View Profile
    • Evolution Engine
Re: SFGUI
« Reply #137 on: June 30, 2011, 01:57:49 pm »
How's the state of this project?

There are broken links on the first post:
Quote from: "Trass3r"



The official site is at: http://dev.boxbox.org/projects/sfgui
Pluma - Plug-in Management Framework

nefx

  • Newbie
  • *
  • Posts: 4
    • View Profile
SFGUI (old thread)
« Reply #138 on: July 02, 2011, 08:43:12 pm »
I have looked into this project, but it is still in development and not ready for use. Anyway it was a good look. Inspired me to write my own GUI.
What I suggest to tank is to hide signals private since currently they are public and anyone can emit a signal.

Tank

  • SFML Team
  • Hero Member
  • *****
  • Posts: 1486
    • View Profile
    • Blog
    • Email
SFGUI (old thread)
« Reply #139 on: July 02, 2011, 09:19:14 pm »
@gsaurus:
The project is still active, but paused due to another project. However I will soon need a GUI for it, so I'll continue on SFGUI then.

@nefx:
Why not extend SFGUI? ;)
Regarding the public signals: I don't see a problem when the user is able to emit signals himself. Any concrete reasons not to do so?

Edit:
@Trass3r: Could you please strike-out the links in the first post?

The project website is currently located at http://redmine.boxbox.org/projects/sfgui .

SuperV1234

  • SFML Team
  • Full Member
  • *****
  • Posts: 190
    • View Profile
SFGUI (old thread)
« Reply #140 on: July 10, 2011, 10:37:35 pm »
Can I use this with SFML.NET?

Richy19

  • Full Member
  • ***
  • Posts: 190
    • View Profile
SFGUI (old thread)
« Reply #141 on: July 14, 2011, 06:35:06 pm »
Are you able to create windows inside the main window?
so make it like a virtual desktop?

Tank

  • SFML Team
  • Hero Member
  • *****
  • Posts: 1486
    • View Profile
    • Blog
    • Email
SFGUI (old thread)
« Reply #142 on: July 19, 2011, 10:41:48 pm »
@SuperV1234:
Not planned on my side. However if someone wants to create a binding, then yes. :)

@Richy19:
Not exactly like that. Windows are top-level windows. However you can create "workspaces" that you can either display or hide, which could be used to simulate virtual desktops.

Tank

  • SFML Team
  • Hero Member
  • *****
  • Posts: 1486
    • View Profile
    • Blog
    • Email
SFGUI (old thread)
« Reply #143 on: August 23, 2011, 10:24:35 am »
Thanks to anttirt and binary1248, we now have sfg::Entry, which is basically a textbox widget.

Next tasks:
- Scrollbars
- Multi-column listbox
- Table layouter

Tank

  • SFML Team
  • Hero Member
  • *****
  • Posts: 1486
    • View Profile
    • Blog
    • Email
SFGUI (old thread)
« Reply #144 on: August 31, 2011, 01:41:26 pm »
News:

binary1248 has implemented scrollbars and sliders. This is how they look like:



Also, a user called Iteem is developing a bitmap renderer (the current rendering engine (called BREW) uses sf::Shapes for visuals only) that provides fancier visuals. Check this out:



Rendering engines are completely replacable, even during runtime. I'm still working on sfg::Table, a table layouter.

Thanks to binary and Iteem for your contributions.

Tank

  • SFML Team
  • Hero Member
  • *****
  • Posts: 1486
    • View Profile
    • Blog
    • Email
SFGUI (old thread)
« Reply #145 on: September 01, 2011, 03:06:06 pm »
sfg::Table is 80% complete, multi-row/-column spanning is missing.


Tank

  • SFML Team
  • Hero Member
  • *****
  • Posts: 1486
    • View Profile
    • Blog
    • Email
SFGUI (old thread)
« Reply #146 on: September 29, 2011, 02:16:03 pm »
I've made good progress on the ListBox widget. It adapts the store/view principle of GTK, that means: On the one hand, you've got a store where your actual data is saved. On the other hand you've got the list box that utilizes the store to fetch the data it renders.

This makes everything rather flexible, because you have full control of the data types and can share stores between multiple list boxes without the need to copy data around.

Example in C++:
Code: [Select]

// Create the store for holding the actual data. The store can be used in
// multiple list boxes or anything else relying on stores.
sfg::ListStore::Ptr store = sfg::ListStore::Create();

// Setup the store's columns.
store->AddColumn<int>();
store->AddColumn<sf::String>();
store->AddColumn<bool>();

// Now create the list box and set the previously created store.
sfg::ListBox::Ptr list_box = sfg::ListBox::Create();

list_box->SetStore( store );

// Finally create the "visible" columns in the list box. We need to attach a
// "cell renderer" to each column so that list box knows how to render the
// contents. This way you can even render, for example, "bool" data as text or
// as fancy checkboxes.
// Of course cell renderers can be shared. Some renderers may have custom
// properties, so you probably have to create more than one.
sfg::TextCellRenderer::Ptr cell_renderer = sfg::TextCellRenderer::Create();

list_box->AppendColumn( sfg::Column( cell_renderer, 1, "Column 0" ) );
list_box->AppendColumn( sfg::Column( cell_renderer, 1, "Column 1" ) );
list_box->AppendColumn( sfg::Column( cell_renderer, 1, "Column 2" ) );

// Btw., the "1" means that the visible list box column refers to column 1 of
// the store.

// Now let's append some data:
store->Append()( 0 )( sf::String( L"Entry 0" ) )( false );
store->Append()( 1 )( sf::String( L"Entry 1" ) )( true );
store->Append()( 2 )( sf::String( L"Entry 2" ) )( false );

// The syntax may look confusing at first, but it makes it possible to insert
// data in a more comfortable way. Every value in each pair of parenthesis
// represents the proper column value of the store.

// Whenever you add, edit or remove data, ALL list boxes that use the store are
// updated automagically.


Results in this:



The list box rendering hasn't been done, yet. So it's just a black rect without the column titles at the top.

Cpl.Bator

  • Hero Member
  • *****
  • Posts: 540
    • View Profile
SFGUI (old thread)
« Reply #147 on: October 10, 2011, 11:48:37 pm »
Very nice work , easy to use , work fine on linux ubuntu x64, sfgui adopted !
Thank you very much.

ps: don't forget image button ! ;)

Tank

  • SFML Team
  • Hero Member
  • *****
  • Posts: 1486
    • View Profile
    • Blog
    • Email
SFGUI (old thread)
« Reply #148 on: October 13, 2011, 12:37:45 pm »
Thank you very much! Expect more stuff to come in the near future, 3 guys are working hard on it. ;)

Btw, can you show screenshots of it working in your project? Would love to see it in action.

victorlevasseur

  • Full Member
  • ***
  • Posts: 206
    • View Profile
SFGUI (old thread)
« Reply #149 on: October 18, 2011, 07:53:05 pm »
Hello,

I recently discover SFGUI : it's a good GUI library for SFML.


I am going to use your library to create a plug-in for a french game creation freeware (Game Develop) (this freeware uses SFML for render). The plug-in will not use the layout widgets, but only the widgets like buttons, entry, scale...
I'm just waiting the developper of Game Develop to add a functionnality that allows plug-ins to access to the list of events produced by PollEvent.
Then, I will begin the plug-in developpment.

Where can I find the SFGUI logo ?
And can I use widgets without any container ?

(Sorry, if I make some english mistakes, I am only 16 and I'm French)