Home » U++ Library support » Look and Chameleon Technology » A little theming
Re: A little theming [message #21520 is a reply to message #21519] |
Sun, 24 May 2009 11:33 |
Didier
Messages: 680 Registered: November 2008 Location: France
|
Contributor |
|
|
The compile problem is not only on MINGW, there is the same problem on linux ==> the "problem" comes from the compiler GCC.
Here is a valid correction but it needs to be optimised (on point 2):
In Theme.cpp
------------
1 - I removed the second template parameter: V is supposed to be a Value type since you use ' v.Is<Upp::String> ' just let C++ inheritance do it's work.
//template <typename T, typename V>
template <typename T>
inline void SetIfNotNull(T& t, Value v)
{
if ( v.Is<Upp::String>() && ((String)v == "null") )
t = Null;
else
if (!IsNull(v))
t = v;
}
2 - You have to add a temporary object: because problems when using temporary references: It is not excluded that will use the address of the passed object which would be completely false for a temporary reference. Even though the problem is still here after correction (img is a temporary to the scope) at least it is visible while reading the code and not left to compiler will.
Value Theme::StringToObject(const String& s, const String& def) {
Vector<String> v = Split(s, ' ');
if (v.GetCount() == 0)
return Null;
if (v[0] == "png") {
Image imag = PNGRaster().LoadFileAny(AppendFileName(dir, def));
ImageBuffer img( imag );
if (img.IsEmpty())
In Theme.h
----------
3 - remove the from the following line
void Theme::LoadEditField(EditField::Style& d, const VectorMap<String, String>& set, const String& dir, const String& file);
Question:
---------
1 - Is there some documentation for the 'theme.ini' file syntax ?
2 - Can I use several themes in one application (like have two tabs not using same theme) or add in 'theme.ini' several different versions of skin for a ctrl ?
Skulpture looks good on linux
|
|
|
|
|
A little theming
|
|
|
Re: A little theming
By: captainc on Wed, 01 October 2008 21:58
|
|
|
Re: A little theming
By: yoco on Thu, 02 October 2008 06:34
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: mirek on Fri, 03 October 2008 17:30
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: unodgs on Fri, 03 October 2008 19:35
|
|
|
Re: A little theming
By: mirek on Fri, 03 October 2008 19:59
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: mirek on Mon, 06 October 2008 09:03
|
|
|
Re: A little theming
|
|
|
Re: A little theming
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: mirek on Sat, 11 October 2008 08:22
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: mirek on Sat, 11 October 2008 08:29
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: mirek on Sat, 11 October 2008 20:19
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: mirek on Sun, 12 October 2008 11:04
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: mrjt on Tue, 14 October 2008 13:14
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: mrjt on Tue, 14 October 2008 14:39
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: mrjt on Wed, 15 October 2008 17:41
|
|
|
Re: A little theming
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: mrjt on Fri, 17 October 2008 00:04
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: chickenk on Sat, 18 October 2008 09:10
|
|
|
Re: A little theming
By: chickenk on Sat, 18 October 2008 09:51
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: mrjt on Mon, 20 October 2008 10:51
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: unodgs on Thu, 23 October 2008 21:06
|
|
|
Re: A little theming
By: tojocky on Fri, 24 October 2008 07:59
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: unodgs on Fri, 24 October 2008 14:53
|
|
|
Re: A little theming
By: tojocky on Sat, 25 October 2008 11:31
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: mirek on Fri, 31 October 2008 14:34
|
|
|
Re: A little theming
By: Infausto on Fri, 06 March 2009 21:01
|
|
|
Re: A little theming
|
|
|
Re: A little theming
|
|
|
Re: A little theming
|
|
|
Re: A little theming
|
|
|
Re: A little theming
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: Didier on Sun, 24 May 2009 11:33
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: tojocky on Sat, 25 October 2008 11:40
|
|
|
Re: A little theming
By: mirek on Fri, 31 October 2008 14:40
|
|
|
Re: A little theming
By: mirek on Sat, 11 October 2008 08:23
|
|
|
Re: A little theming
By: Didier on Sun, 24 May 2009 12:11
|
|
|
Re: A little theming
|
|
|
Re: A little theming
|
|
|
Re: A little theming
|
|
|
Re: A little theming
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: mirek on Fri, 26 June 2009 13:34
|
|
|
Re: A little theming
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: mirek on Tue, 07 July 2009 20:05
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: Alboni on Thu, 27 August 2015 13:46
|
|
|
Re: A little theming
By: Sgifan on Mon, 01 March 2010 19:52
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: Sgifan on Wed, 03 March 2010 21:20
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: Sgifan on Thu, 04 March 2010 21:19
|
|
|
Re: A little theming
|
|
|
Re: A little theming
|
|
|
Re: A little theming
|
|
|
Re: A little theming
By: mrjt on Thu, 01 April 2010 13:36
|
|
|
Re: A little theming
By: Sgifan on Fri, 05 March 2010 10:01
|
|
|
Re: A little theming
By: Alboni on Thu, 27 August 2015 14:25
|
|
|
Re: A little theming
By: Alboni on Thu, 27 August 2015 14:35
|
Goto Forum:
Current Time: Fri Apr 26 22:51:39 CEST 2024
Total time taken to generate the page: 0.06597 seconds
|