Main Menu
Menu

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.

Show posts Menu

Messages - ColaGGS

#1
Help requests / Re: String/letters label
17 March 2014, 15:19:39
0.6.2 label/string letters are being cut again.
#2
Help requests / Re: window flickering in macOs
16 March 2014, 12:36:04
yep i did, but i'll do it again, since I updated XCode so i'll give it a try. And I'll keep doing what i can :)
And that did the trick. It never crossed my mind that i might have overwritten it when i tired install.sh or that new XCode might messed it up after install/upgrade from DP2. Thanks!
#3
Help requests / Re: window flickering in macOs
16 March 2014, 12:28:17
Sorry I have to ask you this, but I got no reply on SFML. Share me your secret how did you get frameworks to work, i checked shared_libs and build frameworks in cmake and compiled it. I probably messed up somewhere. :P
#4
Help requests / Re: window flickering in macOs
15 March 2014, 15:33:50
Thanks, need to figure out SFML, waiting for their response to help me with frameworks. I'll post an update once I sort SFML.
#5
Help requests / Re: window flickering in macOs
15 March 2014, 14:45:20
Ok, cuz last time, in 5.0 we had problems with framework, and now its the other way around. K i'll give it a try
#6
Help requests / Re: window flickering in macOs
15 March 2014, 14:33:28
I'm using SFML template when i create a project, here's flags that xcode uses

-lsfml-system
-lsfml-window
-lsfml-graphics
-lsfml-audio
-lsfml-network
-ltgui

When I created the project instead of using frameworks i told it to use dylibs.
#7
Help requests / window flickering in macOs
15 March 2014, 13:03:09
I just updated my XCode to final release of 5.1.

And I have a problem with tgui, probably gui.draw() is not working or it might be something else.  Code i am about to post works great on linux. Here i get window flickering, which shouldn't happen.

main.cpp:

#include <TGUI/TGUI.hpp>


#include "loginScreen.hpp"

// Here is a small helper for you ! Have a look.
#include "ResourcePath.hpp"

int main(int, char const**)
{
    // Create the main window
    sf::RenderWindow window(sf::VideoMode(800, 600), "SFML window");
    tgui::Gui gui(window);
   
    gui.setGlobalFont("Data/Fonts/DejaVuSans.ttf");
    loginScreen(gui);
   
    gui.get("loginScreen")->show();
   
    // Start the game loop
    while (window.isOpen())
    {
        // Process events
        sf::Event event;
        while (window.pollEvent(event))
        {
            // Close window : exit
            if (event.type == sf::Event::Closed) {
                window.close();
            }

            // Espace pressed : exit
            if (event.type == sf::Event::KeyPressed && event.key.code == sf::Keyboard::Escape) {
                window.close();
            }
           
            gui.handleEvent(event);
        }
       
        tgui::Callback callback;
        while (gui.pollCallback(callback))
        {
            // Make sure that callback comes from the button
            if (callback.id == 1) // login button
            {
            }
        }

        // Clear screen
        window.clear();
       
        gui.draw();


        // Update the window
        window.display();
    }
   
    return EXIT_SUCCESS;
}


loginScreen.hpp:

#ifndef fml_test_loginScreen_hpp
#define fml_test_loginScreen_hpp

void loginScreen( tgui::Gui& gui )
{
   
    tgui::Panel::Ptr loginScreen(gui, "loginScreen");
    loginScreen->setSize(800, 600);
   
    // Create the background image
    tgui::Picture::Ptr picture(*loginScreen);
    picture->load("Data/Backgrounds/loginBackground.tex");
    picture->setSize(800, 600);

   
    tgui::Button::Ptr jebise(*loginScreen);
    jebise->load("Data/Buttons/Black.conf");
    jebise->setSize(80,25);
    jebise->setText("Tuck off");
    jebise->setPosition(100, 100);
    jebise->bindCallback(tgui::Button::LeftMouseClicked);
    jebise->setCallbackId(1);
   
}
#endif



only output i get in terminal is:

objc[2442]: Class SFApplication is implemented in both /Library/Frameworks/sfml-window.framework/Versions/2.1.0/sfml-window and /Users/cola/Desktop/fml test/Debug/fml test.app/Contents/Frameworks/libsfml-window.2.dylib. One of the two will be used. Which one is undefined.
objc[2442]: Class SFOpenGLView is implemented in both /Library/Frameworks/sfml-window.framework/Versions/2.1.0/sfml-window and /Users/cola/Desktop/fml test/Debug/fml test.app/Contents/Frameworks/libsfml-window.2.dylib. One of the two will be used. Which one is undefined.
objc[2442]: Class SFSilentResponder is implemented in both /Library/Frameworks/sfml-window.framework/Versions/2.1.0/sfml-window and /Users/cola/Desktop/fml test/Debug/fml test.app/Contents/Frameworks/libsfml-window.2.dylib. One of the two will be used. Which one is undefined.
objc[2442]: Class SFWindow is implemented in both /Library/Frameworks/sfml-window.framework/Versions/2.1.0/sfml-window and /Users/cola/Desktop/fml test/Debug/fml test.app/Contents/Frameworks/libsfml-window.2.dylib. One of the two will be used. Which one is undefined.
objc[2442]: Class SFWindowController is implemented in both /Library/Frameworks/sfml-window.framework/Versions/2.1.0/sfml-window and /Users/cola/Desktop/fml test/Debug/fml test.app/Contents/Frameworks/libsfml-window.2.dylib. One of the two will be used. Which one is undefined.
objc[2442]: Class SFViewController is implemented in both /Library/Frameworks/sfml-window.framework/Versions/2.1.0/sfml-window and /Users/cola/Desktop/fml test/Debug/fml test.app/Contents/Frameworks/libsfml-window.2.dylib. One of the two will be used. Which one is undefined.
Segmentation fault: 11



Just sfml code without tGui works great.
EDIT: i just updated tGui to 0.6.2, i have same problem.
#8
Help requests / Re: String/letters label
15 March 2014, 12:54:48
Thank you it worked.
#9
Help requests / String/letters label
12 March 2014, 17:10:22
Hello,
Why does label cut letters underline like in the picture in attachment? And how can I configure it to show string/letters properly?

Is it possible, and if it is, how to, place an url as a label? And how to place a picture as a button?

https://i.imgur.com/QMf91tu.jpg
#10
Yep XCode 5.1 worked, but now i get 44 errors saying lexical or preprocessor Issue in FormBuilder. I downloaded from github and compiled it with cmake for xcode.
#11
oh, it is indeed strange, as i posted on apple's forums, and my only response from them was clang is better than gcc. It seems like clang is strangely awful in mavericks, since i came across so many bugs so far. Hm... I'll keep searching. And if something comes up i'll post here.

Now in mean time, gotta find a way to install gcc on mavericks. Thx for the note.

EDIT: Problem caused the Mac 10.9 libc++, the latest libc++ from llvm should fix the problem. Also XCode 5.1 that is going to be released should also fix the problem as well. I will confirm as soon as i get my hands on both of them.
#12
Hello,
I've just installed tgui, tried installing as UNIX Makefile and XCode project, though i didn't seem to understand what the error was about. I found a link that refers that clang might have some bugs. And i will post the error:


Scanning dependencies of target tgui
[  2%] Building CXX object src/TGUI/CMakeFiles/tgui.dir/Callback.cpp.o
In file included from /Users/cola/TGUI-0.6.1/src/TGUI/Callback.cpp:26:
In file included from /Users/cola/TGUI-0.6.1/include/TGUI/Callback.hpp:29:
In file included from /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/map:371:
In file included from /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/__tree:16:
In file included from /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/memory:599:
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/tuple:234:73: error:
      no matching constructor for initialization of
      'std::__1::reference_wrapper<const tgui::Callback>'
             _NOEXCEPT_(is_nothrow_default_constructible<_Hp>::value) : value()
                                                                        ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/tuple:447:23: note:
      in instantiation of member function 'std::__1::__tuple_leaf<0,
      std::__1::reference_wrapper<const tgui::Callback>, false>::__tuple_leaf'
      requested here
    _LIBCPP_CONSTEXPR __tuple_impl()
                      ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/tuple:550:23: note:
      in instantiation of member function
      'std::__1::__tuple_impl<std::__1::__tuple_indices<0>,
      std::__1::reference_wrapper<const tgui::Callback> >::__tuple_impl'
      requested here
    _LIBCPP_CONSTEXPR tuple()
                      ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/functional:1744:11: note:
      in instantiation of member function
      'std::__1::tuple<std::__1::reference_wrapper<const tgui::Callback>
      >::tuple' requested here
          __bound_args_(_VSTD::forward<_BA>(__bound_args)...) {}
          ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/memory:2243:15: note:
      in instantiation of function template specialization
      'std::__1::__bind<std::__1::function<void (const tgui::Callback &)> &,
      std::__1::reference_wrapper<const tgui::Callback>
      >::__bind<std::__1::__bind<std::__1::function<void
      (const tgui::Callback &)> &, std::__1::reference_wrapper<const
      tgui::Callback> >, , void>' requested here
              __first_(_VSTD::forward<_Args1>(get<_I1>(__first_args))...)
              ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/memory:2421:15: note:
      in instantiation of function template specialization
      'std::__1::__libcpp_compressed_pair_imp<std::__1::__bind<std::__1::function<void
      (const tgui::Callback &)> &, std::__1::reference_wrapper<const
      tgui::Callback> >,
      std::__1::allocator<std::__1::__bind<std::__1::function<void
      (const tgui::Callback &)> &, std::__1::reference_wrapper<const
      tgui::Callback> > >,
      2>::__libcpp_compressed_pair_imp<std::__1::__bind<std::__1::function<void
      (const tgui::Callback &)> &, std::__1::reference_wrapper<const
      tgui::Callback> > &&, , 0, >' requested here
            : base(__pc, _VSTD::move(__first_args), _VSTD::move(__second_args),
              ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/functional:992:11: note:
      in instantiation of function template specialization
      'std::__1::__compressed_pair<std::__1::__bind<std::__1::function<void
      (const tgui::Callback &)> &, std::__1::reference_wrapper<const
      tgui::Callback> >,
      std::__1::allocator<std::__1::__bind<std::__1::function<void
      (const tgui::Callback &)> &, std::__1::reference_wrapper<const
      tgui::Callback> > >
      >::__compressed_pair<std::__1::__bind<std::__1::function<void
      (const tgui::Callback &)> &, std::__1::reference_wrapper<const
      tgui::Callback> > &&, >' requested here
        : __f_(piecewise_construct, _VSTD::forward_as_tuple(_VSTD::move(__f)),
          ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/functional:1277:26: note:
      in instantiation of member function
      'std::__1::__function::__func<std::__1::__bind<std::__1::function<void
      (const tgui::Callback &)> &, std::__1::reference_wrapper<const
      tgui::Callback> >,
      std::__1::allocator<std::__1::__bind<std::__1::function<void
      (const tgui::Callback &)> &, std::__1::reference_wrapper<const
      tgui::Callback> > >, void ()>::__func' requested here
            ::new (__f_) _FF(_VSTD::move(__f));
                         ^
/Users/cola/TGUI-0.6.1/src/TGUI/Callback.cpp:43:21: note: in instantiation of
      function template specialization 'std::__1::function<void
      ()>::function<std::__1::__bind<std::__1::function<void
      (const tgui::Callback &)> &, std::__1::reference_wrapper<const
      tgui::Callback> > >' requested here
        mapCallback(std::bind(func, std::cref(m_Callback)), trigger);
                    ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/__functional_base:365:31: note:
      candidate constructor not viable: requires single argument '__f', but no
      arguments were provided
    _LIBCPP_INLINE_VISIBILITY reference_wrapper(type& __f) _NOEXCEPT : _...
                              ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/__functional_base:367:14: note:
      candidate constructor not viable: requires 1 argument, but 0 were provided
    private: reference_wrapper(type&&); public: // = delete; // do not b...
             ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/__functional_base:354:24: note:
      candidate constructor (the implicit copy constructor) not viable: requires
      1 argument, but 0 were provided
class _LIBCPP_TYPE_VIS reference_wrapper
                       ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/__functional_base:354:24: note:
      candidate constructor (the implicit move constructor) not viable: requires
      1 argument, but 0 were provided
1 error generated.
make[2]: *** [src/TGUI/CMakeFiles/tgui.dir/Callback.cpp.o] Error 1
make[1]: *** [src/TGUI/CMakeFiles/tgui.dir/all] Error 2
make: *** [all] Error 2


currently my mac uses clang 5.0.2( llvm 3.3)
#13
If you can send me those libs i would be more then thankful. I will do as you say.
#14
There it goes. I chose vs11.. hmm
#15
-I compiled SFML myself using cmake, after i compiled it, sfml built perfectly fine.
-TGUI_USE_STATIC_STD_LIBS was unchecked when i compiled it. But when I check it, I get tgui-d.lib could not open or tgui.lib could not open, so I left it unchecked.
The only options I changed were adding libs, include folder to properties. So basicly when i compiled sfml and tgui i didnt change any options, left them by default.