----- Original Message ----- From: "taos" <taosxx-list@xxxxxxxxx>
What do you think of using < and >? This would also allow us to implement a working second hypertext link for the LGPL
This solution is to the tag order, and quite sensible to extra < and > characters
For an hypertext link, I would prefer "<a href=%MIT%>MIT license</a>" and "<a href=%LGPL%>LGPL license</a>" since in the user guide translationtool, translators used to manipulate the tags and keep them unchanged. ( or may
be <MIT>MIT license</MIT> and <LGPL>LGPL license</LGPL> ) Regards Loïc PS : the code might look something like that : { ... int tag1start=haikuLicense.FindFirst("<a ",0); int tag1end=haikuLicense.FindFirst(">",tag1start); int tag2=haikuLicense.FindFirst("</a>",tag1end); BString tag1; haikuLicense.CopyInto(tag1,tag1start,tag1end-tag1start); BString part; haikuLicense.CopyInto(part, tag1end+1,tag2-tag1end-1); if( tag1.FindFirst("%MIT%")!=B_ERROR ) fCreditsView->InsertHyperText(part, new OpenFileAction(mitPath.Path())); else if( Tag1.FindFirst("%LGPL%")!=B_ERROR )fCreditsView->InsertHyperText(part, new OpenFileAction(lgplPath.Path()));
else fCreditsView->Insert(part); ... int tag3start=haikuLicense.FindFirst("<a ",tag2+4); int tag3end=haikuLicense.FindFirst(">",tag3start); int tag4=haikuLicense.FindFirst("</a>",tag3end); BString tag3; haikuLicense.CopyInto(tag3,tag3start,tag3end-tag3start); part.Truncate(0); haikuLicense.CopyInto(part, tag3end+1,tag4-tag3end-1); if( tag3.FindFirst("%MIT%")!=B_ERROR ) fCreditsView->InsertHyperText(part, new OpenFileAction(mitPath.Path())); else if( tag3.FindFirst("%LGPL%")!=B_ERROR )fCreditsView->InsertHyperText(part, new OpenFileAction(lgplPath.Path()));
else fCreditsView->Insert(part); ... }