Implementing text-decoration
I'm currently looking at implementing text-decoration. ATM it's specified as an EnumProperty but should be more like a set of enums with certain validation rules applied. I'm unsure about the approach. If anyone already has an idea how it should look like I'd appreciate any insight. My first idea was to implement a special property class (TextDecorationProperty) that handles the conversion of a ListProperty of NCNames to an internal set of variables while at the same time validating the enum combinations. I think my approach would work even if it look a bit awkward. But I wanted to check first so I didn't implement something really ugly. Jeremias Maerki
Re: fo.InlineLevel -- make abstract?
I think, you are right. They should be abstract. On 04.01.2005 00:47:29 Glen Mazza wrote: Any problem with making fo.InlineLevel an abstract class? Any reason why you made it instantiable--or was this just an oversight? (Actually, anyone know why we're not making FObj and FObjMixed abstract as well? I might be missing something here...) Jeremias Maerki
New year - update copyright years
People, we have a new year again, so don't forget to update the copyright years if you change a file. One think that's still on my todo list is to fix the copyright years of all the files that have wrong values (mainly due to my sloppy way of changing license headers when I changed them from short to long). I've got a script from Thomas to do that but I need a good day to do that. :-) Jeremias Maerki
RE: Implementing text-decoration
Jeremias Maerki wrote: I'm currently looking at implementing text-decoration. ATM it's specified as an EnumProperty but should be more like a set of enums with certain validation rules applied. I'm unsure about the approach. If anyone already has an idea how it should look like I'd appreciate any insight. My first idea was to implement a special property class (TextDecorationProperty) that handles the conversion of a ListProperty of NCNames to an internal set of variables while at the same time validating the enum combinations. I think my approach would work even if it look a bit awkward. But I wanted to check first so I didn't implement something really ugly. I think you are on the right track, and it is a curiosity to me why the standard writers did not create a separate datatype for this. The FOray implementation uses a pseudo datatype to handle text decoration, handled the same general way that keeps and spaces are: http://cvs.sourceforge.net/viewcvs.py/foray/foray/foray-fotree/src/java/org/ foray/fotree/value/DtTextDeco.java?view=markup The class that creates and uses the datatype is here: http://cvs.sourceforge.net/viewcvs.py/foray/foray/foray-fotree/src/java/org/ foray/fotree/fo/prop/TextDecoration.java?view=markup After taking this approach (i.e. allowing all of the variations to be stored together), text decoration was implemented properly. IOW, all of the other pieces were already in place, all I had to do was get the data stored and retrieved correctly. Caveat: FOray stores and retrieves properties using a late- or no-binding scheme, so the timing will be different, but I would think the general principle would be the same. HTH. Victor Mote
Re: New year - update copyright years
I'll take care of the web pages when I upload the site... On Jan 4, 2005, at 12:44 AM, Jeremias Maerki wrote: People, we have a new year again, so don't forget to update the copyright years if you change a file. One think that's still on my todo list is to fix the copyright years of all the files that have wrong values (mainly due to my sloppy way of changing license headers when I changed them from short to long). I've got a script from Thomas to do that but I need a good day to do that. :-) Jeremias Maerki Web Maestro Clay -- [EMAIL PROTECTED] - http://homepage.mac.com/webmaestro My religion is simple. My religion is kindness. - HH The 14th Dalai Lama of Tibet
Re: Implementing text-decoration
Victor Mote wrote: Jeremias Maerki wrote: I'm currently looking at implementing text-decoration. ATM it's specified as an EnumProperty but should be more like a set of enums with certain validation rules applied. I'm unsure about the approach. If anyone already has an idea how it should look like I'd appreciate any insight. My first idea was to implement a special property class (TextDecorationProperty) that handles the conversion of a ListProperty of NCNames to an internal set of variables while at the same time validating the enum combinations. I think my approach would work even if it look a bit awkward. But I wanted to check first so I didn't implement something really ugly. I think you are on the right track, and it is a curiosity to me why the standard writers did not create a separate datatype for this. The FOray implementation uses a pseudo datatype to handle text decoration, handled the same general way that keeps and spaces are: http://cvs.sourceforge.net/viewcvs.py/foray/foray/foray-fotree/src/java/org/ foray/fotree/value/DtTextDeco.java?view=markup The class that creates and uses the datatype is here: http://cvs.sourceforge.net/viewcvs.py/foray/foray/foray-fotree/src/java/org/ foray/fotree/fo/prop/TextDecoration.java?view=markup After taking this approach (i.e. allowing all of the variations to be stored together), text decoration was implemented properly. IOW, all of the other pieces were already in place, all I had to do was get the data stored and retrieved correctly. Caveat: FOray stores and retrieves properties using a late- or no-binding scheme, so the timing will be different, but I would think the general principle would be the same. And of course, alt-design had a solution for this, oh, a long, long time ago. It can be found in the usual place, and was even mentioned on the list. That's two solutions so far, and counting. Peter
Re: New year - update copyright years
{Sigh.} Jeremias, you are so particular--anyway, Peter, will you please give Jeremias said greeting so he can proceed? Thanks, Glen --- Jeremias Maerki [EMAIL PROTECTED] wrote: I've got a script from Thomas to do that but I need a good day to do that. :-) Jeremias Maerki