[mapguide-users] Lable problem

Traian Stanev traian.stanev at autodesk.com
Fri Mar 14 14:50:08 EDT 2008


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: mapguide-users-bounces at lists.osgeo.org [mailto:mapguide-users-bounces at lists.osgeo.org] 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: traian.stanev at autodesk.com
To: mapguide-users at lists.osgeo.org
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: mapguide-users-bounces at lists.osgeo.org [mailto:mapguide-users-bounces at lists.osgeo.org] 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: mapguide-users-bounces at lists.osgeo.org [mailto:mapguide-users-bounces at lists.osgeo.org] On Behalf Of ????? ???
Sent: Sunday, March 09, 2008 3:48 AM
To: mapguide-users at lists.osgeo.org
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/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/mapguide-users/attachments/20080314/e8e5c334/attachment.html


More information about the mapguide-users mailing list