Mercurial > projects > dwt-linux
diff dwt/custom/StackLayout.d @ 238:380bad9f6852
reverted char[] to String
author | Frank Benoit <benoit@tionex.de> |
---|---|
date | Mon, 05 May 2008 00:42:55 +0200 |
parents | 17f8449522fd |
children | c0d810de7093 |
line wrap: on
line diff
--- a/dwt/custom/StackLayout.d Sat Apr 26 10:01:30 2008 +0200 +++ b/dwt/custom/StackLayout.d Mon May 05 00:42:55 2008 +0200 @@ -12,6 +12,8 @@ *******************************************************************************/ module dwt.custom.StackLayout; +import dwt.dwthelper.utils; + import dwt.DWT; @@ -128,8 +130,8 @@ } } -char[] getName () { - char[] string = this.classinfo.name; +String getName () { + String string = this.classinfo.name; int index = tango.text.Util.locatePrior( string ,'.'); if (index is string.length ) return string; return string[ index + 1 .. $ ]; @@ -141,11 +143,11 @@ * * @return a string representation of the layout */ -public override char[] toString () { - char[] string = getName ()~" {"; - if (marginWidth !is 0) string ~= "marginWidth="~to!(char[])(marginWidth)~" "; - if (marginHeight !is 0) string ~= "marginHeight="~to!(char[])(marginHeight)~" "; - if (topControl !is null) string ~= "topControl="~to!(char[])(topControl)~" "; +public override String toString () { + String string = getName ()~" {"; + if (marginWidth !is 0) string ~= "marginWidth="~to!(String)(marginWidth)~" "; + if (marginHeight !is 0) string ~= "marginHeight="~to!(String)(marginHeight)~" "; + if (topControl !is null) string ~= "topControl="~to!(String)(topControl)~" "; string = tango.text.Util.trim(string); string ~= "}"; return string;