RE: [AFP Renderer] Increased document size

2015-11-25 Thread sdridi
Hi,

I already did that a long time ago
https://issues.apache.org/jira/browse/FOP-2455

-Message d'origine-
De : Chris Bowditch [mailto:bowditch_ch...@hotmail.com] 
Envoyé : mercredi 25 novembre 2015 17:34
À : fop-dev@xmlgraphics.apache.org
Objet : Re: [AFP Renderer] Increased document size

Hi Seifeddine,

Can you log a bug in JIRA please so this issue is not forgotten?

Thanks,

Chris

On 20/11/2015 14:16, sdr...@iptech-group.com wrote:
>
> Hello,
>
> I’m using FOP Trunk in production and I noticed that the size of AFP 
> documents has substantially increased compared to FOP 1.1. After some 
> debugging, I found out that the issue is located in method equals 
> inside AFPResourceInfo.java; the current code does not handle the case 
> in which the two fields to be compared have null values. As far as I 
> know, two Java instances of the same type are considered equal if they 
> both have null values.
>
> Attached to this email, you find all the files you need to reproduce 
> the afore mentioned issue.
>
> Thanks,
>
> Seifeddine DRIDI
>




Borders in page regions

2015-11-11 Thread sdridi
Hi,

 

Does anybody know why it isn't allowed to set borders in page regions ? The
XSL specs says that border-width and padding values must be 0, but I don't
understand why it is enforcing this restriction, RenderX for instance allows
borders in page regions.

 

Thanks

 

Seifeddine Dridi



RE: How to set uriresolver in 2.0

2015-08-14 Thread sdridi
Hi,

 

You can implement the ResourceResolver then pass an instance to 
FopFactoryBuilder. That way you will be able to resolve URIs however you want.

 

Best regards,

 

Seifeddine Dridi

 

De : Rahman USTA [mailto:rahman.usta...@gmail.com] 
Envoyé : vendredi 14 août 2015 07:47
À : fop-dev@xmlgraphics.apache.org
Objet : How to set uriresolver in 2.0

 

I'm not able to set FOUserAgent#setURIResolver in 2.0 How can I set it ?

 

-- 

Rahman USTA

Istanbul JUG

https://github.com/rahmanusta http://www.kodcu.com/ 



Re: Adding a new layout manager

2013-06-21 Thread sdridi
OK, now I have something working. I borrowed some code from
ListBlockLayoutManager, which is simple enough to understand. 

Luis, is it okay to inherit from BlockStackinLayoutManager even though my
extension does not have any FO properties? What's the best approach that you
would recommend?

Thanks



--
View this message in context: 
http://apache-fop.1065347.n5.nabble.com/Adding-a-new-layout-manager-tp38757p38779.html
Sent from the FOP - Dev mailing list archive at Nabble.com.


Re: Adding a new layout manager

2013-06-21 Thread sdridi
I completely agree. They often say the best way to assess your understanding
of a subject is to try to explain it to someone else. Maybe the time has
come to give something back to this great community :)

Actually, I have been thinking to write a general introduction tutorial to
FOP, because let's say it the current code-base could be quite intimidating
to new developers.









--
View this message in context: 
http://apache-fop.1065347.n5.nabble.com/Adding-a-new-layout-manager-tp38757p38785.html
Sent from the FOP - Dev mailing list archive at Nabble.com.


Adding a new layout manager

2013-06-20 Thread sdridi
Hello people,

I'm working on an extension for FOP similar to  Whitespace management
http://wiki.apache.org/xmlgraphics-fop/WhitespaceManagement  . I want to
start as simple as possible, so my XML extension *fox:best-fit-block* is
only allowed to contain one *fox:alternative* which has an *fo:block*.
The layout manager should be simple to implement and most calls will be
delegated to the appropriate children, but I'm not sure which methods to
implement in /AbstractLayoutManager/. Also, could you briefly explain how to
implement /getNextKnuthElements()/? And do I even need to implement
/getChangedKnuthElements()/?

Thank you in advance for your time

Best Regards

Seifeddine Dridi









--
View this message in context: 
http://apache-fop.1065347.n5.nabble.com/Adding-a-new-layout-manager-tp38757.html
Sent from the FOP - Dev mailing list archive at Nabble.com.


Re: Adding a new layout manager

2013-06-20 Thread sdridi
You have no idea what many hours I spend everyday reading FOP code :). I
understand the big picture of FOP layout engine, but some details are still
blurry in my head. Anyway, I'll continue tinkering with the code until I
figure out what I need exactly.

Thanks for the link btw, but these articles are indeed outdated, maybe it's
time for someone to write a good documentation about FOP' execution
pipeline.



--
View this message in context: 
http://apache-fop.1065347.n5.nabble.com/Adding-a-new-layout-manager-tp38757p38759.html
Sent from the FOP - Dev mailing list archive at Nabble.com.


Re: Adding a new layout manager

2013-06-20 Thread sdridi
Glenn Adams-2 wrote
 I would suggest you not just read code but run it with Eclipse or NetBeans
 to trace the execution process. That is one of the best ways to learn
 actual code behavior.

Yes of course, debugging is my only way to break FOP mystery


Glenn Adams-2 wrote
 Maybe that somebody is you! :)

That would be an honor, but not before I master how FOP works

Back to my main topic of discussion, if anyone can shed some light on FOP
layout engine, I'd be very grateful.



--
View this message in context: 
http://apache-fop.1065347.n5.nabble.com/Adding-a-new-layout-manager-tp38757p38766.html
Sent from the FOP - Dev mailing list archive at Nabble.com.


Re: Adding a new layout manager

2013-06-20 Thread sdridi
Thanks for the links Glenn. I've already read Knuth's paper and I understand
how it works. FOP implementation is also clear to me, more or less...I'm not
trying to reinvent Knuth algorithm neither to modify it, all I want is to
know how to create a layout manager for my fox:best-fit-block element. The
latter is too simple, it doesn't have any FO properties and can only contain
a single fo:block.

I managed to write the following class but it doesn't generate any content
in the output document:


public class BestFitBlockLayoutManager extends AbstractLayoutManager {

static Log log = LogFactory.getLog(BestFitBlockLayoutManager.class);

public BestFitBlockLayoutManager(BestFitBlock node) {
super(node);
}

/** {@inheritDoc} */
public List getNextKnuthElements(LayoutContext context, int alignment) {
if (isFinished())
return null;
List returnList = null;
if (getChildLM() != null) {
returnList = getChildLM().getNextKnuthElements(context, 
alignment);
// add a penalty element, representing a forced page break
returnList.add(new BreakElement(new NonLeafPosition(this, new
Position(this)),
Constants.EN_PAGE, -KnuthElement.INFINITE, EN_PAGE, 
context));

}
setFinished(true);
notifyEndOfLayout();
return returnList;
}
}



--
View this message in context: 
http://apache-fop.1065347.n5.nabble.com/Adding-a-new-layout-manager-tp38757p38769.html
Sent from the FOP - Dev mailing list archive at Nabble.com.


Rendering issue: table with multiple cell spans

2013-04-17 Thread sdridi
Hello,

I'm new to the Apache FOP project and I would like to help fixing this bug 
https://issues.apache.org/jira/browse/FOP-2230
https://issues.apache.org/jira/browse/FOP-2230  . Considering the huge
code base of FOP, I feel kind of lost, so I need some help from people who
are familiar with the code and the rendering pipeline in general. 

So if you can give me some pointers regarding table rendering in FOP, I'd be
very grateful.

Regards

Seifeddine



--
View this message in context: 
http://apache-fop.1065347.n5.nabble.com/Rendering-issue-table-with-multiple-cell-spans-tp38341.html
Sent from the FOP - Dev mailing list archive at Nabble.com.