TrimList
this function will trim a list of strings for the output of a dialog box.
Function <lsl> list TrimList(list dlist, integer length) {
integer i;
list temp = [];
for(i=0;i<llGetListLength(dlist);i++)
{
string text = llList2String(dlist,i);
if (length < llStringLength(text))
{
length = length-1;
string newstring = llGetSubString(text,0, length);
temp += newstring;
}
else
{
temp += text;
}
}
return temp;
}
</lsl>