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 - Maddoggaia

#1
Thank you very much, both examples compiled, though the pop up example didn't display anything (though since it ran it's all good).

Now to play about with it :D
#2
Line 21:    popumMenu->connect("ItemSelected", popupMenuCallback);

and I didn't get any errors with the first or second examples, only the 3rd and 4th, which I did find strange.

all I did was copy and paste the examples you have hosted for 0.7, no alterations, everything is being linked correctly, I went through each example and it was only the last two that threw up the functional has too few arguments.

Errors in Tab example:
1>c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(1149): error C2198: 'void (__cdecl *)(tgui::Gui &,std::string)' : too few arguments for call
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(1137) : see reference to function template instantiation 'void std::_Bind<true,void,void (__cdecl *const )(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui> &>::_Do_call<,0>(std::tuple<>,std::_Arg_idx<0>)' being compiled
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(1137) : see reference to function template instantiation 'void std::_Bind<true,void,void (__cdecl *const )(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui> &>::_Do_call<,0>(std::tuple<>,std::_Arg_idx<0>)' being compiled
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\xrefwrap(283) : see reference to function template instantiation 'void std::_Bind<true,void,void (__cdecl *const )(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui> &>::operator ()<>(void)' being compiled
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\xrefwrap(283) : see reference to function template instantiation 'void std::_Bind<true,void,void (__cdecl *const )(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui> &>::operator ()<>(void)' being compiled
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(228) : see reference to function template instantiation '_Ret std::_Callable_obj<std::_Bind<true,_Ret,void (__cdecl *const )(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui> &>,false>::_ApplyX<_Rx,>(void)' being compiled
1>          with
1>          [
1>              _Ret=void
1>  ,            _Rx=void
1>          ]
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(228) : see reference to function template instantiation '_Ret std::_Callable_obj<std::_Bind<true,_Ret,void (__cdecl *const )(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui> &>,false>::_ApplyX<_Rx,>(void)' being compiled
1>          with
1>          [
1>              _Ret=void
1>  ,            _Rx=void
1>          ]
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(226) : while compiling class template member function 'void std::_Func_impl<_MyWrapper,_Alloc,_Ret,>::_Do_call(void)'
1>          with
1>          [
1>              _Alloc=std::allocator<std::_Func_class<void,>>
1>  ,            _Ret=void
1>          ]
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(495) : see reference to class template instantiation 'std::_Func_impl<_MyWrapper,_Alloc,_Ret,>' being compiled
1>          with
1>          [
1>              _Alloc=std::allocator<std::_Func_class<void,>>
1>  ,            _Ret=void
1>          ]
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(396) : see reference to function template instantiation 'void std::_Func_class<_Ret,>::_Do_alloc<_Myimpl,_Ty,_Alloc>(_Fty &&,_Alloc)' being compiled
1>          with
1>          [
1>              _Ret=void
1>  ,            _Ty=std::_Bind<true,void,void (__cdecl *const )(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui> &>
1>  ,            _Alloc=std::allocator<std::_Func_class<void,>>
1>  ,            _Fty=std::_Bind<true,void,void (__cdecl *const )(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui> &>
1>          ]
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(396) : see reference to function template instantiation 'void std::_Func_class<_Ret,>::_Do_alloc<_Myimpl,_Ty,_Alloc>(_Fty &&,_Alloc)' being compiled
1>          with
1>          [
1>              _Ret=void
1>  ,            _Ty=std::_Bind<true,void,void (__cdecl *const )(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui> &>
1>  ,            _Alloc=std::allocator<std::_Func_class<void,>>
1>  ,            _Fty=std::_Bind<true,void,void (__cdecl *const )(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui> &>
1>          ]
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(385) : see reference to function template instantiation 'void std::_Func_class<_Ret,>::_Reset_alloc<_Ty,std::allocator<std::_Func_class<_Ret,>>>(_Fty &&,_Alloc)' being compiled
1>          with
1>          [
1>              _Ret=void
1>  ,            _Ty=std::_Bind<true,void,void (__cdecl *const )(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui> &>
1>  ,            _Fty=std::_Bind<true,void,void (__cdecl *const )(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui> &>
1>  ,            _Alloc=std::allocator<std::_Func_class<void,>>
1>          ]
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(385) : see reference to function template instantiation 'void std::_Func_class<_Ret,>::_Reset_alloc<_Ty,std::allocator<std::_Func_class<_Ret,>>>(_Fty &&,_Alloc)' being compiled
1>          with
1>          [
1>              _Ret=void
1>  ,            _Ty=std::_Bind<true,void,void (__cdecl *const )(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui> &>
1>  ,            _Fty=std::_Bind<true,void,void (__cdecl *const )(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui> &>
1>  ,            _Alloc=std::allocator<std::_Func_class<void,>>
1>          ]
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(671) : see reference to function template instantiation 'void std::_Func_class<_Ret,>::_Reset<_Ty>(_Fty &&)' being compiled
1>          with
1>          [
1>              _Ret=void
1>  ,            _Ty=std::_Bind<true,void,void (__cdecl *const )(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui> &>
1>  ,            _Fty=std::_Bind<true,void,void (__cdecl *const )(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui> &>
1>          ]
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(671) : see reference to function template instantiation 'void std::_Func_class<_Ret,>::_Reset<_Ty>(_Fty &&)' being compiled
1>          with
1>          [
1>              _Ret=void
1>  ,            _Ty=std::_Bind<true,void,void (__cdecl *const )(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui> &>
1>  ,            _Fty=std::_Bind<true,void,void (__cdecl *const )(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui> &>
1>          ]
1>          c:\users\rei\documents\libraries\tgui-0.7\include\tgui\signal.hpp(153) : see reference to function template instantiation 'std::function<void (void)>::function<std::_Bind<true,void,void (__cdecl *const )(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui> &>>(_Fx &&)' being compiled
1>          with
1>          [
1>              _Fx=std::_Bind<true,void,void (__cdecl *const )(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui> &>
1>          ]
1>          c:\users\rei\documents\libraries\tgui-0.7\include\tgui\signal.hpp(153) : see reference to function template instantiation 'std::function<void (void)>::function<std::_Bind<true,void,void (__cdecl *const )(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui> &>>(_Fx &&)' being compiled
1>          with
1>          [
1>              _Fx=std::_Bind<true,void,void (__cdecl *const )(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui> &>
1>          ]
1>          c:\users\rei\documents\libraries\tgui-0.7\include\tgui\signal.hpp(152) : while compiling class template member function 'std::function<void (void)> tgui::priv::connector<type,Func,std::reference_wrapper<tgui::Gui>>::connect(Func,size_t,std::reference_wrapper<tgui::Gui>)'
1>          with
1>          [
1>              Func=void (__cdecl *)(tgui::Gui &,std::string)
1>          ]
1>          c:\users\rei\documents\libraries\tgui-0.7\include\tgui\signal.hpp(240) : see reference to function template instantiation 'std::function<void (void)> tgui::priv::connector<type,Func,std::reference_wrapper<tgui::Gui>>::connect(Func,size_t,std::reference_wrapper<tgui::Gui>)' being compiled
1>          with
1>          [
1>              Func=void (__cdecl *)(tgui::Gui &,std::string)
1>          ]
1>          c:\users\rei\documents\libraries\tgui-0.7\include\tgui\signal.hpp(240) : see reference to class template instantiation 'tgui::priv::connector<type,Func,std::reference_wrapper<tgui::Gui>>' being compiled
1>          with
1>          [
1>              Func=void (__cdecl *)(tgui::Gui &,std::string)
1>          ]
1>          c:\users\rei\documents\libraries\tgui-0.7\include\tgui\signal.hpp(354) : see reference to function template instantiation 'void tgui::Signal::connect<void(__cdecl *)(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui>>(unsigned int,Func,std::reference_wrapper<tgui::Gui>)' being compiled
1>          with
1>          [
1>              Func=void (__cdecl *)(tgui::Gui &,std::string)
1>          ]
1>          c:\users\rei\documents\projects\sfml projects\sfmltgui\sfmltgui\main.cpp(44) : see reference to function template instantiation 'unsigned int tgui::SignalWidgetBase::connect<void(__cdecl *)(tgui::Gui &,std::string),std::reference_wrapper<tgui::Gui>>(const std::string &,Func,std::reference_wrapper<tgui::Gui>)' being compiled
1>          with
1>          [
1>              Func=void (__cdecl *)(tgui::Gui &,std::string)
1>          ]


Above Line 44:    tabs->connect("TabSelected", onTabSelected, std::ref(gui));
#3
Hello, I have been trying to compile one of the 0.7 examples provided (The login screen example functions, but the rest give the following errors)

Visual Studio 2013 update 5.
OS: Windows 8.1
SFML Version: 2.3.2
TGUI: Visual Studio 2013 x86. (Precompiled)
Both SFML and TGUI are Debug dynamically linked.

1>c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(1149): error C2198: 'void (__cdecl *)(std::string)' : too few arguments for call
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(1137) : see reference to function template instantiation 'void std::_Bind<true,void,void (__cdecl *const )(std::string),>::_Do_call<,>(std::tuple<>,std::_Arg_idx<>)' being compiled
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(1137) : see reference to function template instantiation 'void std::_Bind<true,void,void (__cdecl *const )(std::string),>::_Do_call<,>(std::tuple<>,std::_Arg_idx<>)' being compiled
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\xrefwrap(283) : see reference to function template instantiation 'void std::_Bind<true,void,void (__cdecl *const )(std::string),>::operator ()<>(void)' being compiled
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\xrefwrap(283) : see reference to function template instantiation 'void std::_Bind<true,void,void (__cdecl *const )(std::string),>::operator ()<>(void)' being compiled
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(228) : see reference to function template instantiation '_Ret std::_Callable_obj<std::_Bind<true,_Ret,void (__cdecl *const )(std::string),>,false>::_ApplyX<_Rx,>(void)' being compiled
1>          with
1>          [
1>              _Ret=void
1>  ,            _Rx=void
1>          ]
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(228) : see reference to function template instantiation '_Ret std::_Callable_obj<std::_Bind<true,_Ret,void (__cdecl *const )(std::string),>,false>::_ApplyX<_Rx,>(void)' being compiled
1>          with
1>          [
1>              _Ret=void
1>  ,            _Rx=void
1>          ]
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(226) : while compiling class template member function 'void std::_Func_impl<_MyWrapper,_Alloc,_Ret,>::_Do_call(void)'
1>          with
1>          [
1>              _Alloc=std::allocator<std::_Func_class<void,>>
1>  ,            _Ret=void
1>          ]
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(495) : see reference to class template instantiation 'std::_Func_impl<_MyWrapper,_Alloc,_Ret,>' being compiled
1>          with
1>          [
1>              _Alloc=std::allocator<std::_Func_class<void,>>
1>  ,            _Ret=void
1>          ]
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(396) : see reference to function template instantiation 'void std::_Func_class<_Ret,>::_Do_alloc<_Myimpl,_Ty,_Alloc>(_Fty &&,_Alloc)' being compiled
1>          with
1>          [
1>              _Ret=void
1>  ,            _Ty=std::_Bind<true,void,void (__cdecl *const )(std::string),>
1>  ,            _Alloc=std::allocator<std::_Func_class<void,>>
1>  ,            _Fty=std::_Bind<true,void,void (__cdecl *const )(std::string),>
1>          ]
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(396) : see reference to function template instantiation 'void std::_Func_class<_Ret,>::_Do_alloc<_Myimpl,_Ty,_Alloc>(_Fty &&,_Alloc)' being compiled
1>          with
1>          [
1>              _Ret=void
1>  ,            _Ty=std::_Bind<true,void,void (__cdecl *const )(std::string),>
1>  ,            _Alloc=std::allocator<std::_Func_class<void,>>
1>  ,            _Fty=std::_Bind<true,void,void (__cdecl *const )(std::string),>
1>          ]
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(385) : see reference to function template instantiation 'void std::_Func_class<_Ret,>::_Reset_alloc<_Ty,std::allocator<std::_Func_class<_Ret,>>>(_Fty &&,_Alloc)' being compiled
1>          with
1>          [
1>              _Ret=void
1>  ,            _Ty=std::_Bind<true,void,void (__cdecl *const )(std::string),>
1>  ,            _Fty=std::_Bind<true,void,void (__cdecl *const )(std::string),>
1>  ,            _Alloc=std::allocator<std::_Func_class<void,>>
1>          ]
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(385) : see reference to function template instantiation 'void std::_Func_class<_Ret,>::_Reset_alloc<_Ty,std::allocator<std::_Func_class<_Ret,>>>(_Fty &&,_Alloc)' being compiled
1>          with
1>          [
1>              _Ret=void
1>  ,            _Ty=std::_Bind<true,void,void (__cdecl *const )(std::string),>
1>  ,            _Fty=std::_Bind<true,void,void (__cdecl *const )(std::string),>
1>  ,            _Alloc=std::allocator<std::_Func_class<void,>>
1>          ]
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(671) : see reference to function template instantiation 'void std::_Func_class<_Ret,>::_Reset<_Ty>(_Fty &&)' being compiled
1>          with
1>          [
1>              _Ret=void
1>  ,            _Ty=std::_Bind<true,void,void (__cdecl *const )(std::string),>
1>  ,            _Fty=std::_Bind<true,void,void (__cdecl *const )(std::string),>
1>          ]
1>          c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional(671) : see reference to function template instantiation 'void std::_Func_class<_Ret,>::_Reset<_Ty>(_Fty &&)' being compiled
1>          with
1>          [
1>              _Ret=void
1>  ,            _Ty=std::_Bind<true,void,void (__cdecl *const )(std::string),>
1>  ,            _Fty=std::_Bind<true,void,void (__cdecl *const )(std::string),>
1>          ]
1>          c:\users\rei\documents\libraries\tgui-0.7\include\tgui\signal.hpp(153) : see reference to function template instantiation 'std::function<void (void)>::function<std::_Bind<true,void,void (__cdecl *const )(std::string),>>(_Fx &&)' being compiled
1>          with
1>          [
1>              _Fx=std::_Bind<true,void,void (__cdecl *const )(std::string),>
1>          ]
1>          c:\users\rei\documents\libraries\tgui-0.7\include\tgui\signal.hpp(153) : see reference to function template instantiation 'std::function<void (void)>::function<std::_Bind<true,void,void (__cdecl *const )(std::string),>>(_Fx &&)' being compiled
1>          with
1>          [
1>              _Fx=std::_Bind<true,void,void (__cdecl *const )(std::string),>
1>          ]
1>          c:\users\rei\documents\libraries\tgui-0.7\include\tgui\signal.hpp(152) : while compiling class template member function 'std::function<void (void)> tgui::priv::connector<type,Func>::connect(Func,size_t)'
1>          with
1>          [
1>              Func=void (__cdecl *)(std::string)
1>          ]
1>          c:\users\rei\documents\libraries\tgui-0.7\include\tgui\signal.hpp(240) : see reference to function template instantiation 'std::function<void (void)> tgui::priv::connector<type,Func>::connect(Func,size_t)' being compiled
1>          with
1>          [
1>              Func=void (__cdecl *)(std::string)
1>          ]
1>          c:\users\rei\documents\libraries\tgui-0.7\include\tgui\signal.hpp(240) : see reference to class template instantiation 'tgui::priv::connector<type,Func>' being compiled
1>          with
1>          [
1>              Func=void (__cdecl *)(std::string)
1>          ]
1>          c:\users\rei\documents\libraries\tgui-0.7\include\tgui\signal.hpp(354) : see reference to function template instantiation 'void tgui::Signal::connect<void(__cdecl *)(std::string),>(unsigned int,Func)' being compiled
1>          with
1>          [
1>              Func=void (__cdecl *)(std::string)
1>          ]
1>          c:\users\rei\documents\projects\sfml projects\sfmltgui\sfmltgui\main.cpp(21) : see reference to function template instantiation 'unsigned int tgui::SignalWidgetBase::connect<void(__cdecl *)(std::string),>(const std::string &,Func)' being compiled
1>          with
1>          [
1>              Func=void (__cdecl *)(std::string)
1>          ]


Any help with this would be handy, I have not changed the original Example code, so it's merely a copy and paste job to see if there would be any problems with compiling...

I did a search for the above errors, but most of what I was seeing was to do with a different functional header, and for older versions of TGUI.