A good example for a custom function that takes a string and returns a string is ExpressionFunctionDecap.h/cpp, which is used for making strings lower case.
You can implement a similar function that runs a bidirectional reordering on the string. I recommend using PGBA for this. It is freely available at: http://crl.nmsu.edu/~mleisher/ucdata.html The basic premise - your custom function takes a string argument, runs PGBA on it and returns a reordered string. I guess you will need to be somewhat familiar with C++ to do all this. I did start some work on this a while back, but have not had time to fully implement it. Using UCDATA would involve including a generated data file in the install, which would have taken more time than I had available. However, the general idea worked, I tested it with some Hebrew and Arabic strings. Traian From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Nimrod Cnaan Sent: Friday, March 14, 2008 12:01 PM To: MapGuide Users Mail List Subject: RE: [mapguide-users] Lable problem Hello Traian, you like your suggestion about implementing a reordering custom expression function, but not shore how to write one. Can you lead me the & tell me where to start? Nimrod Cnaan Senior GIS Programmer cell 972525355483 ________________________________ From: [EMAIL PROTECTED] To: [email protected] Date: Mon, 10 Mar 2008 08:15:44 -0700 Subject: RE: [mapguide-users] Lable problem I think he means the text is appearing left-to-right, rather than the correct right-to-left. There is a ticket for that one (#271) and the solution is to implement a bidirectional reordering algorithm. I have such an algorithm, but so far have not had time to attempt to integrate it. Like someone else mentioned, there is a workaround, which involves storing the label strings in reverse in the data source. Now that I think of it, it may be best to implement reordering as a custom expression function that one can use to reorder text. This way, no code changes would be needed apart from the implementation of that custom function. Traian From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Dave Wilson Sent: Monday, March 10, 2008 10:51 AM To: MapGuide Users Mail List Subject: RE: [mapguide-users] Lable problem Does the font you are using exist on the server machine? If not the server will not be able to render it in the AJAX Viewer. Regards, Dave From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of ????? ??? Sent: Sunday, March 09, 2008 3:48 AM To: [email protected] Subject: [mapguide-users] Lable problem Im trying to set a hebrew lable for a layer, but in any font i try to set it in studio it does not show it corectly, can any one help me? ________________________________ Express yourself instantly with MSN Messenger! MSN Messenger<http://clk.atdmt.com/AVE/go/onm00200471ave/direct/01/>
_______________________________________________ mapguide-users mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/mapguide-users
