diff --git a/indra/llui/lllineeditor.cpp b/indra/llui/lllineeditor.cpp
index 0db515ab4120fb1dc77acd3b87e053ef8e0d9833..e053477d58e1acd19074713634a07b5aa117de89 100644
--- a/indra/llui/lllineeditor.cpp
+++ b/indra/llui/lllineeditor.cpp
@@ -2514,20 +2514,3 @@ LLWString LLLineEditor::getConvertedText() const
 	}
 	return text;
 }
-
-namespace LLInitParam
-{
-	template<>
-	bool ParamCompare<LLLinePrevalidateFunc>::equals(const LLLinePrevalidateFunc &a, const LLLinePrevalidateFunc &b)
-	{
-		return false;
-	}
-
-	template<>
-	bool ParamCompare<boost::function<void (LLLineEditor *)> >::equals(
-		const boost::function<void (LLLineEditor *)> &a,
-		const boost::function<void (LLLineEditor *)> &b)
-	{
-		return false;
-	}
-}
diff --git a/indra/llui/lllineeditor.h b/indra/llui/lllineeditor.h
index 6e81969f00055825244b5d3f6c78bcb9bc7ebcf0..3d7bbdff8936102a22a2cefcc7a4a009996e5ef4 100644
--- a/indra/llui/lllineeditor.h
+++ b/indra/llui/lllineeditor.h
@@ -391,15 +391,4 @@ class LLLineEditor
 }; // end class LLLineEditor
 
 
-namespace LLInitParam
-{
-    template<>
-	bool ParamCompare<LLLinePrevalidateFunc>::equals(
-		const LLLinePrevalidateFunc &a, const LLLinePrevalidateFunc &b); 
-
-    template<>
-	bool ParamCompare<boost::function<void (LLLineEditor *)> >::equals(
-		const boost::function<void (LLLineEditor *)> &a, const boost::function<void (LLLineEditor *)> &b); 
-}
-
 #endif  // LL_LINEEDITOR_
diff --git a/indra/llui/llscrollbar.cpp b/indra/llui/llscrollbar.cpp
index 7db34a0608d20641ec38c7f0a944c0db5fe59ac4..cb4147709d5f271d6c6e8b56b192ea0569112d74 100644
--- a/indra/llui/llscrollbar.cpp
+++ b/indra/llui/llscrollbar.cpp
@@ -640,15 +640,3 @@ void LLScrollbar::onLineDownBtnPressed( const LLSD& data )
 {
 	changeLine( mStepSize, TRUE );
 }
-
-
-namespace LLInitParam
-{
-    template<>
-	bool ParamCompare<boost::function<void (S32, LLScrollbar*)> >::equals(
-		const boost::function<void (S32, LLScrollbar*)> &a,
-		const boost::function<void (S32, LLScrollbar*)> &b) 
-	{
-		return false;
-	}
-}
diff --git a/indra/llui/llscrollbar.h b/indra/llui/llscrollbar.h
index e4c5712fb7d12785f0539ccfad4dc06e9a3bdb09..2e95779624e11965b2186b910c530cc7466421dd 100644
--- a/indra/llui/llscrollbar.h
+++ b/indra/llui/llscrollbar.h
@@ -167,11 +167,4 @@ class LLScrollbar
 };
 
 
-namespace LLInitParam
-{
-    template<>
-	bool ParamCompare<boost::function<void (S32, LLScrollbar*)> >::equals(
-		const boost::function<void (S32, LLScrollbar*)> &a, const boost::function<void (S32, LLScrollbar*)> &b); 
-}
-
 #endif  // LL_SCROLLBAR_H
diff --git a/indra/llui/lltexteditor.cpp b/indra/llui/lltexteditor.cpp
index 74373e7803fd428438d79ee0b657172a592c87fa..74ffad0f53ec63c57595a2f9da07c29ee56a88cd 100644
--- a/indra/llui/lltexteditor.cpp
+++ b/indra/llui/lltexteditor.cpp
@@ -990,7 +990,7 @@ void LLTextEditor::removeChar()
 // Add a single character to the text
 S32 LLTextEditor::addChar(S32 pos, llwchar wc)
 {
-	if ( (wstring_utf8_length( getWText() ) + wchar_utf8_length( wc ))  >= mMaxTextByteLength)
+	if ( (wstring_utf8_length( getWText() ) + wchar_utf8_length( wc ))  > mMaxTextByteLength)
 	{
 		make_ui_sound("UISndBadKeystroke");
 		return 0;
diff --git a/indra/llui/llui.cpp b/indra/llui/llui.cpp
index 9a90ee267e2c0ee43b748daa87119997099d8864..ec9220a98420dc4a2cd7a9d89f3a85131209adf4 100644
--- a/indra/llui/llui.cpp
+++ b/indra/llui/llui.cpp
@@ -1918,16 +1918,11 @@ namespace LLInitParam
 		declare("blue", LLColor4::blue);
 	}
 
-	template<>
-	class ParamCompare<const LLFontGL*>
+	bool ParamCompare<const LLFontGL*, boost::false_type>::equals(const LLFontGL* a, const LLFontGL* b)
 	{
-	public:
-		static bool equals(const LLFontGL* a, const LLFontGL* b)
-		{
-			return !(a->getFontDesc() < b->getFontDesc())
-				&& !(b->getFontDesc() < a->getFontDesc());
-		}
-	};
+		return !(a->getFontDesc() < b->getFontDesc())
+			&& !(b->getFontDesc() < a->getFontDesc());
+	}
 
 	TypedParam<const LLFontGL*>::TypedParam(BlockDescriptor& descriptor, const char* _name, const LLFontGL*const value, ParamDescriptor::validation_func_t func, S32 min_count, S32 max_count)
 	:	super_t(descriptor, _name, value, func, min_count, max_count),
diff --git a/indra/llui/llui.h b/indra/llui/llui.h
index f071e8dc47439b206ef7a1882e5edaf7fad58cf9..db18957a97f807b557f3c4ec1871fa238129dbe1 100644
--- a/indra/llui/llui.h
+++ b/indra/llui/llui.h
@@ -436,6 +436,13 @@ namespace LLInitParam
 		static void declareValues();
 	};
 
+	template<>
+	struct ParamCompare<const LLFontGL*, boost::false_type>
+	{
+		static bool equals(const LLFontGL* a, const LLFontGL* b);
+	};
+
+
 	template<>
 	class TypedParam<LLCoordGL>
 	:	public BlockValue<LLCoordGL>
diff --git a/indra/llui/lluictrl.cpp b/indra/llui/lluictrl.cpp
index 84b1c92097f0cc95f076becf8af30573554f7b08..0faff5eff682ec4a76b46071d9213330093f584f 100644
--- a/indra/llui/lluictrl.cpp
+++ b/indra/llui/lluictrl.cpp
@@ -849,24 +849,3 @@ BOOL LLUICtrl::getTentative() const
 // virtual
 void LLUICtrl::setColor(const LLColor4& color)							
 { }
-
-
-namespace LLInitParam
-{
-    template<> 
-	bool ParamCompare<LLUICtrl::commit_callback_t>::equals(
-		const LLUICtrl::commit_callback_t &a, 
-		const LLUICtrl::commit_callback_t &b)
-    {
-    	return false;
-    }
-    
-   
-    template<> 
-	bool ParamCompare<LLUICtrl::enable_callback_t>::equals(
-		const LLUICtrl::enable_callback_t &a, 
-		const LLUICtrl::enable_callback_t &b)
-    {
-    	return false;
-    }
-}
diff --git a/indra/llui/lluictrl.h b/indra/llui/lluictrl.h
index 1d34cb39ec679330c29fd385e43bf2dad13761ab..45fe47772b52da6577559501a2be98684d0122e0 100644
--- a/indra/llui/lluictrl.h
+++ b/indra/llui/lluictrl.h
@@ -327,21 +327,4 @@ class LLUICtrl
 	class DefaultTabGroupFirstSorter;
 };
 
-namespace LLInitParam
-{   
-    template<> 
-	bool ParamCompare<LLUICtrl::commit_callback_t>::equals(
-		const LLUICtrl::commit_callback_t &a, 
-		const LLUICtrl::commit_callback_t &b); 
-		
-    template<> 
-	bool ParamCompare<LLUICtrl::enable_callback_t>::equals(
-		const LLUICtrl::enable_callback_t &a, 
-		const LLUICtrl::enable_callback_t &b); 
-    
-    template<>
-	bool ParamCompare<LLLazyValue<LLColor4> >::equals(
-		const LLLazyValue<LLColor4> &a, const LLLazyValue<LLColor4> &b); 
-}
-
 #endif  // LL_LLUICTRL_H
diff --git a/indra/llui/lluiimage.cpp b/indra/llui/lluiimage.cpp
index ab0d65e731fd7d212fed0f6e368298033aee1143..51828e5731114bfae9eb754133d9c45515330dac 100644
--- a/indra/llui/lluiimage.cpp
+++ b/indra/llui/lluiimage.cpp
@@ -152,8 +152,7 @@ namespace LLInitParam
 	}
 
 	
-	template<>
-	bool ParamCompare<LLUIImage*>::equals(
+	bool ParamCompare<LLUIImage*, boost::false_type>::equals(
 		LLUIImage* const &a,
 		LLUIImage* const &b)
 	{
diff --git a/indra/llui/lluiimage.h b/indra/llui/lluiimage.h
index 4ec24e98dc2d50e0b735dccf277ee6b794a0d075..9f505bea7912b610e2d3eb1a4c9e372a6df9afd6 100644
--- a/indra/llui/lluiimage.h
+++ b/indra/llui/lluiimage.h
@@ -108,8 +108,10 @@ namespace LLInitParam
 	// Need custom comparison function for our test app, which only loads
 	// LLUIImage* as NULL.
 	template<>
-	bool ParamCompare<LLUIImage*>::equals(
-		LLUIImage* const &a, LLUIImage* const &b);
+	struct ParamCompare<LLUIImage*, boost::false_type>
+	{
+		static bool equals(LLUIImage* const &a, LLUIImage* const &b);
+	};
 }
 
 typedef LLPointer<LLUIImage> LLUIImagePtr;
diff --git a/indra/llxuixml/llinitparam.cpp b/indra/llxuixml/llinitparam.cpp
index 1b867b79c975adcd12c28718901dedaac85ed5e3..1abd411f3733faf076a83f68483405c06ebc905e 100644
--- a/indra/llxuixml/llinitparam.cpp
+++ b/indra/llxuixml/llinitparam.cpp
@@ -127,7 +127,7 @@ namespace LLInitParam
 
 	bool BaseBlock::submitValue(const Parser::name_stack_t& name_stack, Parser& p, bool silent)
 	{
-		if (!deserializeBlock(p, boost::make_iterator_range(name_stack.begin(), name_stack.end())))
+		if (!deserializeBlock(p, std::make_pair(name_stack.begin(), name_stack.end())))
 		{
 			if (!silent)
 			{
@@ -304,11 +304,11 @@ namespace LLInitParam
 	bool BaseBlock::deserializeBlock(Parser& p, Parser::name_stack_range_t name_stack)
 	{
 		BlockDescriptor& block_data = getBlockDescriptor();
-		bool names_left = !name_stack.empty();
+		bool names_left = name_stack.first != name_stack.second;
 
 		if (names_left)
 		{
-			const std::string& top_name = name_stack.front().first;
+			const std::string& top_name = name_stack.first->first;
 
 			ParamDescriptor::deserialize_func_t deserialize_func = NULL;
 			Param* paramp = NULL;
@@ -331,10 +331,11 @@ namespace LLInitParam
 				}
 			}
 					
-			Parser::name_stack_range_t new_name_stack(++name_stack.begin(), name_stack.end());
+			Parser::name_stack_range_t new_name_stack(name_stack.first, name_stack.second);
+			++new_name_stack.first;
 			if (deserialize_func)
 			{
-				return deserialize_func(*paramp, p, new_name_stack, name_stack.empty() ? -1 : name_stack.front().second);
+				return deserialize_func(*paramp, p, new_name_stack, name_stack.first == name_stack.second ? -1 : name_stack.first->second);
 			}
 		}
 
@@ -346,7 +347,7 @@ namespace LLInitParam
 			Param* paramp = getParamFromHandle((*it)->mParamHandle);
 			ParamDescriptor::deserialize_func_t deserialize_func = (*it)->mDeserializeFunc;
 
-			if (deserialize_func && deserialize_func(*paramp, p, name_stack, name_stack.empty() ? -1 : name_stack.front().second))
+			if (deserialize_func && deserialize_func(*paramp, p, name_stack, name_stack.first == name_stack.second ? -1 : name_stack.first->second))
 			{
 				mLastChangedParam = (*it)->mParamHandle;
 				return true;
@@ -499,33 +500,7 @@ namespace LLInitParam
 		return param_changed;
 	}
 
-
-	template<>
-	bool ParamCompare<boost::function<void (const std::string &,void *)> >::equals(
-	   const boost::function<void (const std::string &,void *)> &a,
-	   const boost::function<void (const std::string &,void *)> &b)
-	{
-		return false;
-	}
-
-	template<>
-	bool ParamCompare<boost::function<void (const LLSD &,const LLSD &)> >::equals(
-	   const boost::function<void (const LLSD &,const LLSD &)> &a,
-	   const boost::function<void (const LLSD &,const LLSD &)> &b)
-	{
-		return false;
-	}
-
-	template<>
-	bool ParamCompare<boost::function<void (void)> >::equals(
-		const boost::function<void (void)> &a,
-		const boost::function<void (void)> &b)
-	{
-		return false;
-	}
-
-	template<>
-	bool ParamCompare<LLSD>::equals(const LLSD &a, const LLSD &b)
+	bool ParamCompare<LLSD, boost::false_type>::equals(const LLSD &a, const LLSD &b)
 	{
 		return false;
 	}
diff --git a/indra/llxuixml/llinitparam.h b/indra/llxuixml/llinitparam.h
index 88bc43050407c819ac9431850b164b5195c1e274..193d8c1f64ae046e3a773819ee066c9359045e69 100644
--- a/indra/llxuixml/llinitparam.h
+++ b/indra/llxuixml/llinitparam.h
@@ -39,25 +39,31 @@
 #include <stddef.h>
 #include <boost/function.hpp>
 #include <boost/bind.hpp>
-#include <boost/range/iterator_range.hpp>
+#include <boost/type_traits/is_convertible.hpp>
 #include "llregistry.h"
 #include "llmemory.h"
 
 
 namespace LLInitParam
 {
-    template <typename T> 
-    class ParamCompare {
-    public:
-    	static bool equals(const T &a, const T &b);
+	template <typename T, typename IS_BOOST_FUNCTION = boost::is_convertible<T, boost::function_base>::type >
+    struct ParamCompare 
+	{
+    	static bool equals(const T &a, const T &b)
+		{
+			return a == b;
+		}
     };
     
-    template<class T>
-    bool ParamCompare<T>::equals(const T &a, const T&b)
-    {
-    	return a == b;
-    }
-
+	// boost function types are not comparable
+	template<typename T>
+	struct ParamCompare<T, boost::true_type>
+	{
+		static bool equals(const T&a, const T &b)
+		{
+			return false;
+		}
+	};
 
 	// default constructor adaptor for InitParam Values
 	// constructs default instances of the given type, returned by const reference
@@ -192,7 +198,7 @@ namespace LLInitParam
 		};
 
 		typedef std::vector<std::pair<std::string, S32> >			name_stack_t;
-		typedef boost::iterator_range<name_stack_t::const_iterator>	name_stack_range_t;
+		typedef std::pair<name_stack_t::const_iterator, name_stack_t::const_iterator>	name_stack_range_t;
 		typedef std::vector<std::string>							possible_values_t;
 
 		typedef boost::function<bool (void*)>															parser_read_func_t;
@@ -535,7 +541,7 @@ namespace LLInitParam
 		{ 
 			self_t& typed_param = static_cast<self_t&>(param);
 			// no further names in stack, attempt to parse value now
-			if (name_stack.empty())
+			if (name_stack.first == name_stack.second)
 			{
 				if (parser.readValue<T>(typed_param.mData.mValue))
 				{
@@ -886,7 +892,7 @@ namespace LLInitParam
 			self_t& typed_param = static_cast<self_t&>(param);
 			value_t value;
 			// no further names in stack, attempt to parse value now
-			if (name_stack.empty())
+			if (name_stack.first == name_stack.second)
 			{
 				// attempt to read value directly
 				if (parser.readValue<value_t>(value))
@@ -1541,7 +1547,7 @@ namespace LLInitParam
 			
 			static bool deserializeParam(Param& param, Parser& parser, const Parser::name_stack_range_t& name_stack, S32 generation)
 			{
-				if (name_stack.empty())
+				if (name_stack.first == name_stack.second)
 				{
 					//std::string message = llformat("Deprecated value %s ignored", getName().c_str());
 					//parser.parserWarning(message);
@@ -1600,7 +1606,7 @@ namespace LLInitParam
 		{
 			self_t& typed_param = static_cast<self_t&>(param);
 			// type to apply parse direct value T
-			if (name_stack.empty())
+			if (name_stack.first == name_stack.second)
 			{
 				if(parser.readValue<T>(typed_param.mData.mValue))
 				{
@@ -1811,24 +1817,11 @@ namespace LLInitParam
 		}
 	};
 
-    template<>
-	bool ParamCompare<boost::function<void (const std::string &,void *)> >::equals(
-		const boost::function<void (const std::string &,void *)> &a,
-		const boost::function<void (const std::string &,void *)> &b);
-	
-	template<>
-	bool ParamCompare<boost::function<void (const LLSD &,const LLSD &)> >::equals(
-		const boost::function<void (const LLSD &,const LLSD &)> &a,
-		const boost::function<void (const LLSD &,const LLSD &)> &b);
-
-	template<>
-	bool ParamCompare<boost::function<void (void)> >::equals(
-		const boost::function<void (void)> &a,
-		const boost::function<void (void)> &b);
-
-
-	template<>
-	bool ParamCompare<LLSD>::equals(const LLSD &a, const LLSD &b);
+	template<> 
+	struct ParamCompare<LLSD, boost::false_type>
+	{
+		static bool equals(const LLSD &a, const LLSD &b);
+	};
 }
 
 #endif // LL_LLPARAM_H
diff --git a/indra/llxuixml/lluicolor.cpp b/indra/llxuixml/lluicolor.cpp
index ef0fa5d63424599a4bbe108981e039d91621fbda..0065edb3094f17b0fe68c795a9d35d8dea6a2dd1 100644
--- a/indra/llxuixml/lluicolor.cpp
+++ b/indra/llxuixml/lluicolor.cpp
@@ -58,14 +58,9 @@ bool LLUIColor::isReference() const
 namespace LLInitParam
 {
 	// used to detect equivalence with default values on export
-	template<>
-	class ParamCompare<LLUIColor>
+	bool ParamCompare<LLUIColor, boost::false_type>::equals(const LLUIColor &a, const LLUIColor &b)
 	{
-	public:
-		static bool equals(const LLUIColor &a, const LLUIColor &b)
-		{
-			// do not detect value equivalence, treat pointers to colors as distinct from color values
-			return (a.mColorPtr == NULL && b.mColorPtr == NULL ? a.mColor == b.mColor : a.mColorPtr == b.mColorPtr);
-		}
-	};
+		// do not detect value equivalence, treat pointers to colors as distinct from color values
+		return (a.mColorPtr == NULL && b.mColorPtr == NULL ? a.mColor == b.mColor : a.mColorPtr == b.mColorPtr);
+	}
 }
diff --git a/indra/llxuixml/lluicolor.h b/indra/llxuixml/lluicolor.h
index 365f61003b49c2c120b640e6a661ae73c36f272a..aff81a695d809ddc161ae216cde4f631bb589a1e 100644
--- a/indra/llxuixml/lluicolor.h
+++ b/indra/llxuixml/lluicolor.h
@@ -11,11 +11,12 @@
 #define LL_LLUICOLOR_H_
 
 #include "v4color.h"
+#include <boost/type_traits/integral_constant.hpp> // for boost::false_type
 
 namespace LLInitParam
 {
-	template<typename T>
-	class ParamCompare;
+	template<typename T, typename IS_BOOST_FUNCTION>
+	struct ParamCompare;
 }
 
 class LLUIColor
@@ -36,10 +37,19 @@ class LLUIColor
 	bool isReference() const;
 
 private:
-	friend class LLInitParam::ParamCompare<LLUIColor>;
+	friend struct LLInitParam::ParamCompare<LLUIColor, boost::false_type>;
 
 	const LLColor4* mColorPtr;
 	LLColor4 mColor;
 };
 
+namespace LLInitParam
+{
+	template<>
+	struct ParamCompare<class LLUIColor, boost::false_type>
+	{
+		static bool equals(const class LLUIColor& a, const class LLUIColor& b);
+	};
+}
+
 #endif
diff --git a/indra/newview/skins/default/xui/en/panel_edit_profile.xml b/indra/newview/skins/default/xui/en/panel_edit_profile.xml
index b728c23bc576745dece0212780cc38d28a58b926..0202323dcf9baa43da4501652808125ff0c153dc 100644
--- a/indra/newview/skins/default/xui/en/panel_edit_profile.xml
+++ b/indra/newview/skins/default/xui/en/panel_edit_profile.xml
@@ -139,6 +139,7 @@
        layout="topleft"
        left="120"
        top="30"
+       max_length="511"
        name="sl_description_edit"
        width="115"
        word_wrap="true">
@@ -194,6 +195,7 @@
        layout="topleft"
        left="120"
        top="195"
+       max_length="254"
        name="fl_description_edit"
        width="115"
        word_wrap="true">