Fop Viewer

classic Classic list List threaded Threaded
20 messages Options
Reply | Threaded
Open this post in threaded view
|

Fop Viewer

richardw-2

Hi,

I'm considering doing some work on the FOP viewer package.
I want to embed it in an application I'm developing and find
it lacking in certain ways. In particular I want to:

1. Separate out the preview panels and control logic from the
buttons and dialog to make it easier to use elsewhere.

2. Fix/enable anti-aliasing where appropriate.

3. Add options to view two or more pages at a time.

4. Add a continuous scrolling mode similar to that used by
acrobat reader.

5. Add fit-width and fit-to-page zoom options.

6. Add (optional) thumbnail slider windows.

Does this sound reasonable and useful to anyone else? Does it
conflict with any work anyone else is doing on this area ?
Does anyone see any obvious pitfalls, reasons why this isn't
going to work or reasons why it should be delayed ?

Richard

Reply | Threaded
Open this post in threaded view
|

Re: Fop Viewer

Jeremias Maerki

On 07.06.2005 15:01:04 richardw wrote:
>
> Hi,
>
> I'm considering doing some work on the FOP viewer package.
> I want to embed it in an application I'm developing and find
> it lacking in certain ways. In particular I want to:
>
> 1. Separate out the preview panels and control logic from the
> buttons and dialog to make it easier to use elsewhere.

That was on my long-term task list. I'm glad you want to give it a try.

> 2. Fix/enable anti-aliasing where appropriate.

Good.

> 3. Add options to view two or more pages at a time.

Good.

> 4. Add a continuous scrolling mode similar to that used by
> acrobat reader.

Interesting. Good luck with this one. Not so important IMO.

> 5. Add fit-width and fit-to-page zoom options.

Very good!

> 6. Add (optional) thumbnail slider windows.

That could be expensive, but if you manage: cool.

> Does this sound reasonable and useful to anyone else? Does it
> conflict with any work anyone else is doing on this area ?

I don't think so. There's only Renaud Richardet's work on the Java2D/AWT
renderer in FOP CVS HEAD which might have some impact on what you're
doing. More below.

> Does anyone see any obvious pitfalls, reasons why this isn't
> going to work or reasons why it should be delayed ?

I think the continuous scrolling and the thumbnails might be a bit
tricky but this is nothing that can't be handled. I'm sure you know that
we've frozen the branch where FOP 0.20.5 came from and we are working on
the redesign which should have its first release later this year. I
assume you need the improved viewer for 0.20.5. That's ok even if you
invest some work in this area because there were no big changes in this
area. At least, I think it should be easy to port your improved viewer
into CVS HEAD later if you don't actually want to implement it directly
for CVS HEAD which we (FOP committers) would prefer. Just keep in mind
that we won't apply any patches for the maintenance branch anymore.

If you do want to do the work on the CVS HEAD code (redesign) then we
need to talk to Renaud and get his work on the Java2D/AWT Renderer
finished, so you actually have something to work on.

Finally, I can only say that I'm thrilled that someone would really like
to improve the viewer since it was always below "being cool" until now.
:-)

If you need help, just yell.

Jeremias Maerki

Reply | Threaded
Open this post in threaded view
|

Re: Fop Viewer

richardw-2
Jeremias Maerki writes:
 > > 6. Add (optional) thumbnail slider windows.
 >
 > That could be expensive, but if you manage: cool.

Are there any hard limits I should be observing with regard to memory
etc. ?

 > > Does anyone see any obvious pitfalls, reasons why this isn't
 > > going to work or reasons why it should be delayed ?
 >
 > I think the continuous scrolling and the thumbnails might be a bit
 > tricky but this is nothing that can't be handled. I'm sure you know that
 > we've frozen the branch where FOP 0.20.5 came from and we are working on
 > the redesign which should have its first release later this year. I
 > assume you need the improved viewer for 0.20.5. That's ok even if you
 > invest some work in this area because there were no big changes in this
 > area. At least, I think it should be easy to port your improved viewer
 > into CVS HEAD later if you don't actually want to implement it directly
 > for CVS HEAD which we (FOP committers) would prefer. Just keep in mind
 > that we won't apply any patches for the maintenance branch anymore.

I'm quite happy to develop straight on the cvs head code.

 > If you do want to do the work on the CVS HEAD code (redesign) then we
 > need to talk to Renaud and get his work on the Java2D/AWT Renderer
 > finished, so you actually have something to work on.

That would be useful if it's going to cause significant changes.
I'll probably be starting work fairly soon.

 > Finally, I can only say that I'm thrilled that someone would really like
 > to improve the viewer since it was always below "being cool" until now.
 > :-)
 >
 > If you need help, just yell.

Thanks,

Richard

Reply | Threaded
Open this post in threaded view
|

Re: Fop Viewer

Jeremias Maerki

On 08.06.2005 10:36:34 richardw wrote:
> Jeremias Maerki writes:
>  > > 6. Add (optional) thumbnail slider windows.
>  >
>  > That could be expensive, but if you manage: cool.
>
> Are there any hard limits I should be observing with regard to memory
> etc. ?

Hard limits no, but imagine a document with 10'000 pages (I know that's
an extreme example). Creating the thumbnails for every page will take a
lot of time and memory. And by default Java provides very little memory
and since we're talking about end-user applications here, these VM
parameter may not be set very high. I guess the thumbnails should only
be created on demand and possibly held in a cache with SoftReferences so
the GC can reclaim the space if necessary. On the other side the
individual pages will take up much more space than the thumbnails, but
at least in this area there are already some preparations to temporarily
store the pages to disk.

>  > > Does anyone see any obvious pitfalls, reasons why this isn't
>  > > going to work or reasons why it should be delayed ?
>  >
>  > I think the continuous scrolling and the thumbnails might be a bit
>  > tricky but this is nothing that can't be handled. I'm sure you know that
>  > we've frozen the branch where FOP 0.20.5 came from and we are working on
>  > the redesign which should have its first release later this year. I
>  > assume you need the improved viewer for 0.20.5. That's ok even if you
>  > invest some work in this area because there were no big changes in this
>  > area. At least, I think it should be easy to port your improved viewer
>  > into CVS HEAD later if you don't actually want to implement it directly
>  > for CVS HEAD which we (FOP committers) would prefer. Just keep in mind
>  > that we won't apply any patches for the maintenance branch anymore.
>
> I'm quite happy to develop straight on the cvs head code.

Cool.

>  > If you do want to do the work on the CVS HEAD code (redesign) then we
>  > need to talk to Renaud and get his work on the Java2D/AWT Renderer
>  > finished, so you actually have something to work on.
>
> That would be useful if it's going to cause significant changes.
> I'll probably be starting work fairly soon.

It's not only useful, but a prerequisite as there's currently no working
Java2D/AWT renderer in CVS HEAD. So this means we have to speed that
task up a little. I'll contact Renaud off-list just in case he doesn't
see this.

>  > Finally, I can only say that I'm thrilled that someone would really like
>  > to improve the viewer since it was always below "being cool" until now.
>  > :-)
>  >
>  > If you need help, just yell.
>
> Thanks,
>
> Richard



Jeremias Maerki

Reply | Threaded
Open this post in threaded view
|

Re: Fop Viewer

Renaud Richardet
In reply to this post by richardw-2
Bonjour

Jeremias Maerki wrote:

>On 07.06.2005 15:01:04 richardw wrote:
>  
>
>>Hi,
>>
>>I'm considering doing some work on the FOP viewer package.
>>    
>>
Great!

<snip/>

>If you do want to do the work on the CVS HEAD code (redesign) then we
>need to talk to Renaud and get his work on the Java2D/AWT Renderer
>finished, so you actually have something to work on.
>

I just cleaned the patch that I submitted some long time ago. It should
work now. Please see my other mail to the list for details.

Richard, once this patch is applied, you might want to look at
org/apache/fop/render/awt/AWTRenderer.java
I would say that you can either build on top of that (what I would
recommand), or make your own Renderer, like I did for PNGRenderer or
TiffRenderer (you'll have to inherit from Java2DRenderer, and grab the
(rendered) BufferedImage with getPageImage() ).

>Finally, I can only say that I'm thrilled that someone would really like
>to improve the viewer since it was always below "being cool" until now.
>:-)  
>
A nice front-end for FOP would be great!

>If you need help, just yell.  
>
Same here: just ask. I would be happy to help you getting started.

HTH,
Renaud

PS: My apologies for not showing up on the FOP-list for a long time. I
just started a new job at Wyona (Z?rich, content management system with
Apache Lenya), and I'm quite busy ATM.
PS2: And a huge Thank you to you all. My (tiny) experience with FOP
allowed me to get in contact with the right people, and eventually find
a job in an open source commited company. Just great :-)
PS3: I've been following the list, and I have to say that it seems to me
that FOP is moving in a real good direction. Keep up!

--
Renaud Richardet
Wyona Inc.  -   Open Source Content Management   -   Apache Lenya
[hidden email]                   http://www.wyona.com




Reply | Threaded
Open this post in threaded view
|

Re: Fop Viewer

GlenMazza
> Renaud
>
> PS: My apologies for not showing up on the FOP-list for a long time. I
> just started a new job at Wyona (Z?rich, content management system with
> Apache Lenya), and I'm quite busy ATM.
> PS2: And a huge Thank you to you all. My (tiny) experience with FOP
> allowed me to get in contact with the right people, and eventually find
> a job in an open source commited company. Just great :-)
> PS3: I've been following the list, and I have to say that it seems to me
> that FOP is moving in a real good direction. Keep up!
>
> --
> Renaud Richardet
> Wyona Inc.  -   Open Source Content Management   -   Apache Lenya
> [hidden email]                   http://www.wyona.com
>

Fantastic!  I'm very happy for you.

Glen

Reply | Threaded
Open this post in threaded view
|

Re: Fop Viewer

Clay Leeds-2
In reply to this post by Renaud Richardet
On Jun 8, 2005, at 2:14 PM, Renaud Richardet wrote:

> PS: My apologies for not showing up on the FOP-list for a long time. I
> just started a new job at Wyona (Z├╝rich, content management system
> with Apache Lenya), and I'm quite busy ATM.
> PS2: And a huge Thank you to you all. My (tiny) experience with FOP
> allowed me to get in contact with the right people, and eventually
> find a job in an open source commited company. Just great :-)
> PS3: I've been following the list, and I have to say that it seems to
> me that FOP is moving in a real good direction. Keep up!
>
> --
> Renaud Richardet
> Wyona Inc.  -   Open Source Content Management   -   Apache Lenya
> [hidden email]                   http://www.wyona.com

That's great news! Congratulations! And thank you for letting us know!

Regards,

Web Maestro Clay
--
<[hidden email]> - <http://homepage.mac.com/webmaestro/>
My religion is simple. My religion is kindness.
- HH The 14th Dalai Lama of Tibet

Reply | Threaded
Open this post in threaded view
|

Re: Fop Viewer

richardw-2
In reply to this post by Renaud Richardet
Renaud Richardet writes:
 > I just cleaned the patch that I submitted some long time ago. It should
 > work now. Please see my other mail to the list for details.

Thanks to both you and Jeremias for moving so quickly on this. I've
checked out the new code and am working on the changes now,

 > PS: My apologies for not showing up on the FOP-list for a long time. I
 > just started a new job at Wyona

Good luck,

Richard

Reply | Threaded
Open this post in threaded view
|

Re: Fop Viewer

Renaud Richardet
Bonjour,

[hidden email] wrote:

>Renaud Richardet writes:
> > I just cleaned the patch that I submitted some long time ago. It should
> > work now. Please see my other mail to the list for details.
>
>Thanks to both you and Jeremias for moving so quickly on this. I've
>checked out the new code and am working on the changes now,
>  
>
You're welcome.
Again: just ask if you have questions.

> > PS: My apologies for not showing up on the FOP-list for a long time. I
> > just started a new job at Wyona
>
>Good luck,
>  
>
Thanks

Cheers,
Renaud
Reply | Threaded
Open this post in threaded view
|

Re: Fop Viewer

richardw-2
In reply to this post by richardw-2
[hidden email] writes:
 > I'm considering doing some work on the FOP viewer package.

The first patch has now been submitted.

The following improvements have been made:

 1. Separated out the preview panels and control logic from the
buttons and dialog to make it easier to use elsewhere. There's
a new PreviewPanel class which contains the basic logic. The
PreviewDialog surrounds this with the familiar controls.

 2. Added continuous scrolling and continuous facing modes
similar to those used by acrobat reader.

 3. Added facility to drag scroll area with any drag on that area.

 4. Add fit-width and fit-to-page zoom options.

 5. Added a load of mnemonics to menus.

I still intend to:

 1. Add (optional) thumbnail slider windows.

 2. Add a ruler on the top and the left side of the preview frame
showing inches / centimeters.

Someone else needs to fix the non-english resource files.

Comments are welcome,

Richard

Reply | Threaded
Open this post in threaded view
|

Re: Fop Viewer

GlenMazza
Thanks for the helping our project Richard!  FOP/XSL is a fascinating
mathematical equation, and the clearer and rawer we can make that
equation, the more it will attract the best computer scientists and
mathematicians from around the world to help us work on determining it.  
Reading your credentials on your website is only further confirming this
for me.

(Sorry though <red face/>, I hope someone else can help out with this
patch--renderers have not been my focus for a long time...)

Regards,
Glen


[hidden email] wrote:

>[hidden email] writes:
> > I'm considering doing some work on the FOP viewer package.
>
>The first patch has now been submitted.
>
>The following improvements have been made:
>
> 1. Separated out the preview panels and control logic from the
>buttons and dialog to make it easier to use elsewhere. There's
>a new PreviewPanel class which contains the basic logic. The
>PreviewDialog surrounds this with the familiar controls.
>
> 2. Added continuous scrolling and continuous facing modes
>similar to those used by acrobat reader.
>
> 3. Added facility to drag scroll area with any drag on that area.
>
> 4. Add fit-width and fit-to-page zoom options.
>
> 5. Added a load of mnemonics to menus.
>
>I still intend to:
>
> 1. Add (optional) thumbnail slider windows.
>
> 2. Add a ruler on the top and the left side of the preview frame
>showing inches / centimeters.
>
>Someone else needs to fix the non-english resource files.
>
>Comments are welcome,
>
>Richard
>
>
>  
>

Reply | Threaded
Open this post in threaded view
|

Re: Fop Viewer

Jeremias Maerki
In reply to this post by richardw-2
The receipt of Richard's ICLA has now been documented:
+notinavail:Richard Wheeldon:Richard Wheeldon:[hidden email]:Signed CLA

I'll review his patch tomorrow. I'll also take care of the german and
french translations.

On 14.06.2005 14:13:02 richardw wrote:

> [hidden email] writes:
>  > I'm considering doing some work on the FOP viewer package.
>
> The first patch has now been submitted.
>
> The following improvements have been made:
>
>  1. Separated out the preview panels and control logic from the
> buttons and dialog to make it easier to use elsewhere. There's
> a new PreviewPanel class which contains the basic logic. The
> PreviewDialog surrounds this with the familiar controls.
>
>  2. Added continuous scrolling and continuous facing modes
> similar to those used by acrobat reader.
>
>  3. Added facility to drag scroll area with any drag on that area.
>
>  4. Add fit-width and fit-to-page zoom options.
>
>  5. Added a load of mnemonics to menus.
>
> I still intend to:
>
>  1. Add (optional) thumbnail slider windows.
>
>  2. Add a ruler on the top and the left side of the preview frame
> showing inches / centimeters.
>
> Someone else needs to fix the non-english resource files.
>
> Comments are welcome,
>
> Richard



Jeremias Maerki

Reply | Threaded
Open this post in threaded view
|

Re: Fop Viewer

Luca Furini-2
In reply to this post by richardw-2
Jeremias Maerki wrote:

> I'll review his patch tomorrow. I'll also take care of the german and
> french translations.

I can take care of the italian translation.

Regards
     Luca


Reply | Threaded
Open this post in threaded view
|

Re: Fop Viewer

Renaud Richardet
> I can take care of the italian translation.
 
and me the french-one.
please tell me the bug-number where the patch has been posted, thanks

Regards,
Renaud
Reply | Threaded
Open this post in threaded view
|

Re: Fop Viewer

Jeremias Maerki
Already taken care of, although my French is probably not as good as
yours. You're welcome to improve.

The patch was:
http://issues.apache.org/bugzilla/show_bug.cgi?id=35358
http://marc.theaimsgroup.com/?l=fop-cvs&m=111883866614698&w=2
The patch is already applied.


On 15.06.2005 21:06:33 Renaud Richardet wrote:
> > I can take care of the italian translation.
>  
> and me the french-one.
> please tell me the bug-number where the patch has been posted, thanks
>
> Regards,
> Renaud



Jeremias Maerki

Reply | Threaded
Open this post in threaded view
|

RE: Fop Viewer

Andreas L Delmelle
> -----Original Message-----
> From: Jeremias Maerki [mailto:[hidden email]]
>

Hi,

> Already taken care of, although my French is probably not as good as
> yours. You're welcome to improve.

Dutch would be mine (or Simon's), if wanted/needed.

Cheers,

Andreas


Reply | Threaded
Open this post in threaded view
|

Re: Fop Viewer

Renaud Richardet
Bonjour,

> Already taken care of, although my French is probably not as good as
> yours. You're welcome to improve.

You french is fine, Jeremias. Still, I did some clean-up (see patch).

Cheers,
Renaud
Reply | Threaded
Open this post in threaded view
|

Re: Fop Viewer

GlenMazza
In reply to this post by Andreas L Delmelle
And I can change Robert's spelling to American English...   ;-)

Glen


Andreas L. Delmelle wrote:

>>-----Original Message-----
>>From: Jeremias Maerki [mailto:[hidden email]]
>>
>>    
>>
>
>Hi,
>
>  
>
>>Already taken care of, although my French is probably not as good as
>>yours. You're welcome to improve.
>>    
>>
>
>Dutch would be mine (or Simon's), if wanted/needed.
>
>Cheers,
>
>Andreas
>
>
>
>  
>

Reply | Threaded
Open this post in threaded view
|

Re: Fop Viewer

Clay Leeds-2
I think that's 'merican... And I've got the Californian, dude!

Web Maestro Clay

On Jun 15, 2005, at 7:39 PM, Glen Mazza wrote:

> And I can change Robert's spelling to American English...   ;-)
>
> Glen
>
> Andreas L. Delmelle wrote:
>
>>> -----Original Message-----
>>> From: Jeremias Maerki [mailto:[hidden email]]
>>>
>>>
>>
>> Hi,
>>
>>
>>> Already taken care of, although my French is probably not as good as
>>> yours. You're welcome to improve.
>>>
>>
>> Dutch would be mine (or Simon's), if wanted/needed.
>>
>> Cheers,
>>
>> Andreas
>>
>>
>>
>>
>
>

Regards,

Web Maestro Clay
--
<[hidden email]> - <http://homepage.mac.com/webmaestro/>
My religion is simple. My religion is kindness.
- HH The 14th Dalai Lama of Tibet

Reply | Threaded
Open this post in threaded view
|

Re: Fop Viewer

Jeremias Maerki
Seriously, I don't see a problem having a Viewer_en_US.properties file
in there. But I guess it would go a it too far having a
Viewer_en_US_CA.properties or else I'd have to come up with at least a
dozen variants for Swiss German. :-) I actually wrote one variant
already just for the fun of it.

On 16.06.2005 06:04:09 The Web Maestro wrote:

> I think that's 'merican... And I've got the Californian, dude!
>
> Web Maestro Clay
>
> On Jun 15, 2005, at 7:39 PM, Glen Mazza wrote:
> > And I can change Robert's spelling to American English...   ;-)
> >
> > Glen
> >
> > Andreas L. Delmelle wrote:
> >
> >>> -----Original Message-----
> >>> From: Jeremias Maerki [mailto:[hidden email]]
> >>>
> >>>
> >>
> >> Hi,
> >>
> >>
> >>> Already taken care of, although my French is probably not as good as
> >>> yours. You're welcome to improve.
> >>>
> >>
> >> Dutch would be mine (or Simon's), if wanted/needed.
> >>
> >> Cheers,
> >>
> >> Andreas
> >>
> >>
> >>
> >>
> >
> >
>
> Regards,
>
> Web Maestro Clay
> --
> <[hidden email]> - <http://homepage.mac.com/webmaestro/>
> My religion is simple. My religion is kindness.
> - HH The 14th Dalai Lama of Tibet



Jeremias Maerki