gui.cpp

changeset 10
5b0579997e9b
parent 7
098e3c4949c6
child 11
323390a03294
equal deleted inserted replaced
9:2467f92d3473 10:5b0579997e9b
310 310
311 str zText; 311 str zText;
312 switch (obj->getType ()) { 312 switch (obj->getType ()) {
313 case OBJ_Comment: 313 case OBJ_Comment:
314 zText = static_cast<LDComment*> (obj)->zText; 314 zText = static_cast<LDComment*> (obj)->zText;
315
316 // Remove leading whitespace
317 while (~zText && zText[0] == ' ')
318 zText -= -1;
315 break; 319 break;
316 320
317 case OBJ_Empty: 321 case OBJ_Empty:
318 break; // leave it empty 322 break; // leave it empty
319 323
338 break; 342 break;
339 343
340 case OBJ_Quad: 344 case OBJ_Quad:
341 { 345 {
342 LDQuad* quad = static_cast<LDQuad*> (obj); 346 LDQuad* quad = static_cast<LDQuad*> (obj);
343 zText.format ("%s, %s, %s", 347 zText.format ("%s, %s, %s, %s",
344 quad->vaCoords[0].getStringRep ().chars(), 348 quad->vaCoords[0].getStringRep ().chars(),
345 quad->vaCoords[1].getStringRep ().chars(), 349 quad->vaCoords[1].getStringRep ().chars(),
346 quad->vaCoords[2].getStringRep ().chars(), 350 quad->vaCoords[2].getStringRep ().chars(),
347 quad->vaCoords[3].getStringRep ().chars()); 351 quad->vaCoords[3].getStringRep ().chars());
348 } 352 }

mercurial