Issue Details (XML | Word | Printable)

Key: FOR-187
Type: Improvement Improvement
Status: Open Open
Priority: Major Major
Assignee: Unassigned
Reporter: Nicola Ken Barozzi
Votes: 0
Watchers: 1
Operations

If you were logged in you would be able to see more operations.
Forrest

Redefine project documentation dirs

Created: 10/Jun/04 11:53 PM   Updated: 25/Jan/07 04:06 AM
Return to search
Component/s: Core operations
Affects Version/s: None
Fix Version/s: None

Time Tracking:
Not Specified

Issue Links:
Blocker
 
Incorporates
 
Reference
 


 Description  « Hide
We should finalize all discussions about where to put sources and extensions in the projects.

 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Nicola Ken Barozzi added a comment - 10/Jun/04 11:55 PM
This is a summary and final decision-vote about the new dir structure
that Forrest will have in version 0.7 .

"Cleaning Forrest source directory madness"
http://nagoya.apache.org/eyebrowse/ReadMsg?listName=forrest-dev@xml.apache.org&msgNo=5715

Below is a summary of the results that have come from this thread:

Conceptually:

  documentation
    content -> model
      - files to process (1)
      - files not to process (2)
    resources -> controller
    skins -> view

We would have use definable (KISS)

files to process-dir (1)
files not to process-dir (2)

What can [files to process (1)] contain?

- *.xml (documentdtd, faq, changes, todo, status, etc)
- *.html (html4, to be tidied)
- *.xhtml (xhtml1, xhtml2-dev)
- *.wiki
- *.png,gif,etc

The default content dirs 1,2 would be:

  documentation/
    content/*.xml (1)
    content/images/*.png (1)
    content/raw/foo.html (2)

The only special dir that will remain is "raw", and it seems that there
is a real-life use case for it.

Mind me, we still add a **.* matcher at the end of the
content-handling pipeline, so that content/** can still contain anything
(ie cocoon can proces it but in this case can also decide to just pass
along).

But as you know in this way I cannot easily cater for the special case
in which I want to explicitly have something as-is, like for example a
raw document-dtd xml file.

So the content dir is about all content, that Forrest *may* alter.
The raw dir is about content that Forrest may *not* alter in any way.

Dave Brondsema added a comment - 11/Jun/04 11:33 PM
document2fo.xsl is currently very inflexible with regard to including images in the PDF. If we can use a cocoon pipeline here, that would be great. If not, we might want to consider a single directory for content, and differentiate the files using site.xml (this approach was discussed earlier, but I don't remember the advantages/disadvantages right now). This would let the XSL find the images in most if not all cases.

Other (future) output formats may have similar problems inlining images.


fyi, here's how it works now. Relative references to images will break if the image is in the raw directory because the relative reference is only correct in the build/site/ dir not in the src/ dir which we need.
      <xsl:variable name="imgpath">
      <xsl:choose>
        <!-- resources image dir -->
        <xsl:when test="starts-with(string(@src),'images/')">
          <xsl:value-of select="concat($imagesdir,substring-after(@src,'images'))"/>
        </xsl:when>
        <!-- already absolute -->
        <xsl:when test="contains(string(@src),':') or starts-with(string(@src),'/')">
          <xsl:value-of select="@src"/>
        </xsl:when>
        <!-- relative to document -->
        <xsl:otherwise><xsl:value-of select="concat($xmlbasedir,@src)"/></xsl:otherwise>
      </xsl:choose>
      </xsl:variable>

Nicola Ken Barozzi added a comment - 22/Oct/04 04:22 PM
Stephan E. Schlierf wrote:
...
> So the problem is that I placed my png-files in
> src/domentation/content/xdocs/images/
> and fop expects them in
> src/documentation/resources/images/
> At least, after moving them to src/documentation/resources/images/ they are
> correctly displayed in a pdf-file.
>
> I was a little bit confused: I thought I should place my images in that
> directory where the images are located after a "forrest seed".

Nicola Ken Barozzi added a comment - 22/Oct/04 10:31 PM
Remember to review the docs.

In particular this paragraph is deprecated:

 http://forrest.apache.org/docs/your-project.html#images

Juan Jose Pablos added a comment - 23/Oct/04 12:08 PM
Forrest behaves as explained on that document. So we need to remove the code at the same time, for both fo and html documents.

Nicola Ken Barozzi added a comment - 23/Oct/04 11:14 PM
The code has not been removed for compatibility reasons. I agree that we must remove the code, and have Forrest help the user in moving files to the new location.

Ross Gardler added a comment - 10/Dec/05 12:48 AM
This task will be much easier to complete once we have moved to Locationmap on all internals.
Moving out of 0.8 roadmap as that is the release that will include the LM stuff.