Date   

calculate color variable based on current chapter #PDF

elementalsource@...
 

Hi all,

OT 2.5.4, PDF. I'm trying to set a variable based on the outputclass value of the current <chapter> element in a bookmap.

bookmap
|_chapter outputclass="foo"
  |_mapref...
|_chapter outputclass="bar"
  |_mapref...

This variable needs to trigger a color change within that chapter. So in chapter 1, I want colorX to be blue and in chapter 2 I want colorX to be red, for example.

Using this:

<xsl:variable name="acme.sectiontype" select="//*[contains(@class, ' bookmap/chapter ')]/@outputclass"/>

It seems that the variable is calculated initially, so that I do get colorX set to blue, but then it's never calculated again, so colorX doesn't change to red in chapter 2.

I suspect that either the subsequent chapter elements are getting lost in the merge or that my xpath is wrong or that I just need to be doing this some other way.

Any ideas?

Many thanks,
Leigh


Re: DITA-OT PDF output generated with properties table UncheckedXPathException #DITA-OT

Mike Reck
 

Hi,

to clarify my question a bit. The following extension works, but I don't think it is an elegant or correct solution.

<xsl:when test="xs:string(number(ancestor::*[contains(@class, ' reference/properties ')][1]/@keycol)) = xs:string($entryCol)">

Therefore I am looking for other solutions.

Part of the properties table in refernce topic:
        <properties relcolwidth="25* 25* 50*" frame="all">
            <prophead>
                <proptypehd>LED</proptypehd>



Thanks

Regards

Apollo102


Re: Source for error message

Toshihiko Makita
 

Hi Scott,

> File file:/C:/my_image.eps not found

.eps images are not usually used as image format.
Are you outputting PDF from DITA instances?
Then what PDF plug-in and PDF Formatter are you using?

Regards,

-- 
/*----------------------------------------------------------------------- 
 Toshihiko Makita
 Development Group. Antenna House, Inc. Ina Branch
 Web site:
 http://www.antenna.co.jp/
 http://www.antennahouse.com/
 -----------------------------------------------------------------------*/ 


Re: Source for error message

scott ashmead
 

I use Oxygen to search the entire DITA-OT folder and all DITA-OT subfolders  using the following regular expression:
"File.*?not found"
I get two matches in file DITA-messages.xml, but neither of the messages contain the text that generates the error message.
Scott

On Monday, July 6, 2020, 07:00:12 PM EDT, Lief Erickson <lief.erickson@...> wrote:


Was there a message ID (e.g., DOTA001F) associated with the error? What did the command-line look like (i.e., what options did you pass)?

It's not clear where you searched for the error message. The error messages are described in the docs, but you're right, something like "File %1 not found" is not there.

Error messages are generated from the source code, potentially from Java.
 

On Mon, Jul 6, 2020 at 3:37 PM scott ashmead via groups.io <scott_ashmead=yahoo.com@groups.io> wrote:
Hi DITA users,

I've purposely created the following error when I use a command-line DITA-OT transform using a dita-map as my input.

File file:/C:/my_image.eps not found

Does anyone know where in the DITA-OT this error message is generated? I've used all sorts of searches, including regular expression to try to find this.

Thank you!
Scott


Re: Source for error message

Lief Erickson
 

Was there a message ID (e.g., DOTA001F) associated with the error? What did the command-line look like (i.e., what options did you pass)?

It's not clear where you searched for the error message. The error messages are described in the docs, but you're right, something like "File %1 not found" is not there.

Error messages are generated from the source code, potentially from Java.
 


On Mon, Jul 6, 2020 at 3:37 PM scott ashmead via groups.io <scott_ashmead=yahoo.com@groups.io> wrote:
Hi DITA users,

I've purposely created the following error when I use a command-line DITA-OT transform using a dita-map as my input.

File file:/C:/my_image.eps not found

Does anyone know where in the DITA-OT this error message is generated? I've used all sorts of searches, including regular expression to try to find this.

Thank you!
Scott


DITA-OT PDF output generated with properties table UncheckedXPathException #DITA-OT

Mike Reck
 

Hi,

I am using DITA-OT version = 3.4.1.

The keycol attribute of the properties table is empty in my document.

I get the error message in the log file:
Error: The following error occurred while executing this line:
.... \Dita-Open-Toolkit\plugins\org.dita.pdf2\build.xml:278: net.sf.saxon.trans.UncheckedXPathException: Cannot compare xs:string to xs:double

The problem seems to be caused by a template in the file Dita-Open-Toolkit\plugins\org.dita.pdf2\xsl\fo\reference-elements.xsl.

  <xsl:template match="*[contains(@class, ' reference/proptype ') or contains(@class, ' reference/propvalue ') or contains(@class, ' reference/propdesc ')]">
    <xsl:param name="entryCol"/> 

Since the keycol attribute is empty, the following comparison obviously leads to an error:

 <xsl:choose>
      <xsl:when test="number(ancestor::*[contains(@class, ' reference/properties ')][1]/@keycol) = $entryCol">

$entryCol is an empty string and number returns xs:double.

How should I modify this comparison so that no error occurs? Or have I overlooked something else?

Thanks

Regards,

Apollo102


Source for error message

scott ashmead
 

Hi DITA users,

I've purposely created the following error when I use a command-line DITA-OT transform using a dita-map as my input.

File file:/C:/my_image.eps not found

Does anyone know where in the DITA-OT this error message is generated? I've used all sorts of searches, including regular expression to try to find this.

Thank you!
Scott


[ann][virtual] Why #content practitioners should care about #research and journals | 8 July 2020 @ 15:00 UTC

Liz Fraley
 

Wednesday, 8 July 2020  @ 15:45 UTC
( 8:45am Los Angeles | 11:45am New York | 3:45pm London | 8:15pm Bangalore )

Register: https://bit.ly/room42-01


Why should practitioners care about research and journals?

Ah, that’s the question, isn’t it? We're looking forward to exploring it with you in Room 42.

Room 42 takes the best of webinars, podcasting, and online teaching for a virtual experience that is more interactive and more inclusive. It's designed to bring practitioners together with academics to share knowledge about new and ongoing communication research in an approachable, accessible way so practitioners can make micro-improvements to their content.

In our debut session, George Hayhoe, Professor emeritus of Mercer University School of Engineering, Editor-in-Chief, IEEE Transactions on Professional Communication, STC Fellow, and IEEE Life Fellow, will be in the room.

George says that there are three things—professional practice, teaching, and journal editorship—that, when considered together, have significantly informed his approach to the role of the technical communicator.

He will explore the reasons why practitioners should care about research and journals and tell you how the collaboration between both sides serves our entire profession.


Register: https://bit.ly/room42-01

-:-

Room 42 sessions are recorded before a live studio audience. You can ask questions in advance (when you register) or during the discussion.


Re: Relationships on Multiple Axes? #reltable

Ron Wheeler
 

I am not sure that I understand both your problems fully but free advice occasionally is worth more than the cost.

I think that reltables can do what you want but I would start with a test of 10 entries to see if it does before you do all 4K+
(Use keyrefs - see below)

Keys are the way to avoid hardcoding links.
Every topic gets a key that says where it is located on the disk.
References to the topic use key as the link.
Keys are stored in separate file(s) so they are easy to maintain.
If you relocate a topic file or give it a better name, just change the reference to the key. Any menu or reltable that refers to the topic will not have to be found and fixed.
Very handy if you need to generate many documents using your topics.


On 2020-07-03 3:13 p.m., Paul Mazaitis wrote:
Hi all,

I've got a fairly hefty set of topics (4k+) that have sparse relationships on multiple axes.

By analogy: 

- some of my topics have a shape (square, triangle, circle, etc.)
- some of my topics have a color (orange, blue, grey, etc.)
- some of my topics have both shape and color
- some of my topics have neither (a majority, thankfully)

What I'd really like to do is handle these relationships with reltables: set up the relationships in a map, and then (somehow) generate labeled lists in topics as appropriate (these topics share this shape; these topics share this color).

However, from what I can tell, reltables (and all of the resulting functionality) only operate on one dimension; a union is made of all available reltables, and all relationships are generated from that (and any extra information about a subgrouping is lost). But! I may have missed something, so I hope it's okay to ask:

Is there any way to get multiple kinds of topic relationships into a DITA documentation set without hard coding the links?

Many thanks!

     -Paul


Relationships on Multiple Axes? #reltable

Paul Mazaitis
 

Hi all,

I've got a fairly hefty set of topics (4k+) that have sparse relationships on multiple axes.

By analogy: 

- some of my topics have a shape (square, triangle, circle, etc.)
- some of my topics have a color (orange, blue, grey, etc.)
- some of my topics have both shape and color
- some of my topics have neither (a majority, thankfully)

What I'd really like to do is handle these relationships with reltables: set up the relationships in a map, and then (somehow) generate labeled lists in topics as appropriate (these topics share this shape; these topics share this color).

However, from what I can tell, reltables (and all of the resulting functionality) only operate on one dimension; a union is made of all available reltables, and all relationships are generated from that (and any extra information about a subgrouping is lost). But! I may have missed something, so I hope it's okay to ask:

Is there any way to get multiple kinds of topic relationships into a DITA documentation set without hard coding the links?

Many thanks!

     -Paul


[ann][webinar] Collaboration Made Simple with Oxygen Content Fusion #Oxygen

alin_belu@...
 

Hello, 
 
Our series of weekly live events continues next Wednesday (July 8) with the “Collaboration Made Simple with Oxygen Content Fusion” webinar! 
 
Mihaela Calotescu, software developer at Syncro Soft, will present the various ways Oxygen Content Fusion can empower technical authors with the use of its latest features. In this webinar, you will learn how you can use Oxygen Content Fusion to: 
* Share or reassign ownership of tasks 
* Assign tasks only to specific collaborators 
* Share complex DITA files that contain key definitions and profiled content 
* Share interlinked files in any XML format 
* Share with SMEs templates that will be filled in with technical data 
* Receive content drafts from SMEs in a structured format 
* Track the document revisions 
 
This is a free event and you can register at http://www.oxygenxml.com/evs2020-7.html 
 
Check the full list of the upcoming webinars and follow the links to see more details and register for free: 
 
Best regards, 
Alin

--
Alin Belu
Oxygen XML Editor


Re: XSL-FO two-page layout

renderxxep
 

Below is an XSL that you could adopt to the Antennahouse area tree format. This does n-up processing of RenderX's intermediate format to 2-up and more.

From the comments:

        This style sheet performs transformations on the XEP intermediate format (XEPOUT)

        to format various layouts of documents. 

        

        It is based on the <xep:transform> element which can apply an affine matix

        transformation to content. This is used to shrink pages to fit within the

        output page. It is also based on the <xep:translate> element to move pages

        in a grid layout in the new document.

        

        The stylesheet is used to take an input document and create various styles of output

        by shrinking and translating input pages from the document into a new output document

        with these pages.

        

        It does assume all the pages are uniform, all being the same dimensions of the first

        page. The scaling and configuration are based on this layout. It does work woth both

        landscape and portrait documents. And of course, it does not work with documents with

        intra-document links or bookmarks. It is meant to produce a print output document with

        the desired n-up layout.

        2-up: Two per page

            opposite final layout

            scaled to (width/height) for portrait

            scaled to (height/width) for landscape

            2 cols, 1 row for portrait

            1 col, 2 rows for landscape

        4-up: Four per page

            same final layout

            scaled to 1/2

        6-up: Six per page

            opposite final layout

            scaled to 1/2 (width/height) for portrait

            scaled to 1/2 (height/width) for landscape

            3 cols, 2 rows for portrait

            2 cols, 3 rows for landscape

        9-up: Nine per page 

            same final layout

            scaled to 1/3

        16-up: Sixteen per page 

            same final layout

 

            scaled to 1/4

 


Re: XSL-FO two-page layout

tokukobayashi2002
 

Hi!

AH Formatter can treat each page of PDF as a vector image. Therefore, if you want to place two A5 pages on top of an A4 page, you can do the following. The first step is to generate a PDF with A5 page master. Next, using the page master of A4, place two pages of A5 PDF on it in order as images.

I remember making samples a long time ago. If you need help, please inform me.

Best regards,

Tokushige Kobayashi
Antenna House, Inc.


2020-06-30 03:16 に Nicholas Mucks via groups.io さんは書きました:

Hi Mica,
That's it: page imposition.
We're using Antenna House.
How might you approach this instead?
On Monday, June 29, 2020, 10:17:10 AM PDT, Mica Semrick
<mica@silentumbrella.com> wrote:
Hey Nick,
Which PDF formatter are you using?
I think your approach might be off, as this generally isn't page level
formatting. The feature is called "page imposition."
-m
On June 29, 2020 9:15:22 AM PDT, "Nicholas Mucks via groups.io"
<urbanrobots=yahoo.com@groups.io> wrote:

Hello,
We're trying to create a two-page layout where each printed page has
two pages on it. Although creating a two-column layout is simple
enough, we're having difficult with the static content since it
still shows one footer that spans the bottom of the page across the
two columns.
Has anyone created a PDF that displays two pages side by side in
landscape orientation?
Thanks for your time.
- Nick
Links:
------
[1] https://dita-users.groups.io/g/main/message/45571
[2] https://groups.io/mt/75195062/2985344
[3] https://dita-users.groups.io/g/main/post
[4] https://dita-users.groups.io/g/main/editsub/2985344
[5] https://dita-users.groups.io/g/main/leave/defanged


How correct is your Simplified Chinese Index? #DITA-OT #PDF

Toshihiko Makita
 

Hi List,

 

If you are publishing DITA documents that contains <indexterm>, you may make index pages by specifying backmatter/booklists/indexlist. Also if your publication contains Simplified Chinese localization, the indexlist will be generated by sorting <indexterm> using following sort keys:

 

   pinyin-reading/strokes/radical/GB0 code

 

However there is very headache problem in making index pages. A Hanzi (Chinese Character) has sometimes plural pinyin readings and  only the most frequently used pinyin reading is adopted for sorting/grouping <indexterm>.

 

For instance:

 

  1. "速系" has reading "tiao2 su4 xi4 tong3" and the meaning is "Speed control system".
  2. "调查结" has reading "diao4 cha2 jie2 guo3" and the meaning is "Survey results".

 

1. should be grouped into "T" and 2. should grouped into "D" according to its readings.

Surprisingly they are all grouped into "D" group unconditionally because  representative reading defined in Unihan database (ftp://unicode.org/Public/13.0.0/ucdxml/ucd.unihan.flat.zip) for "" is "diao4".

 

Here is sample PDF result generated by PDF2 plug-in (DITA-OT 3.5.1).




This is well-known problem and is not avoidable as long as the index-sorting program uses ICU (http://userguide.icu-project.org/collation) or Java collator directly. (Both collator may uses pinyin-reading defined in Unihan database)

We (Antenna House) has been working on this problem and developed new dictionary based index sorting in I18N Index Library (https://www.antennahouse.com/i18n-index-library). This is still under the development but we can generate correct results for above example. (Outputted via PDF5-ML plug-in https://github.com/AntennaHouse/pdf5-ml)



The dictionary based index-sorting outputs the following log:

     [xslt] [readKeyFile][DEBUG] Unihan database entry=41377
     [xslt] [readDictionaryFile][DEBUG] Dictionary entry=189082
     [xslt] [readDictionaryFile][DEBUG] User dictionary entry=5
     [xslt] [getKey][DEBUG] Processing indexterm=调速系统
     [xslt] [processHanziKey][DEBUG] Got pinyin from dictionary! word=调速 pinyin=tiao2 su4
     [xslt] [processHanziKey][DEBUG] Got pinyin from dictionary! word=系统 pinyin=xi4 tong3
     [xslt] [getKey][DEBUG] Processing indexterm=调查结果
     [xslt] [processHanziKey][DEBUG] Got pinyin from dictionary! word=调查结果 pinyin=diao4 cha2 jie2 guo3

It shows that dictionary based method is useful for generating Simplified Chinese index pages. We hope to refine this library function more accurate to automatically generate index pages.

If you have any interest about this library, could you offer your Simplified Chinese DITA publication data for estimation?

  1. The needed file is merged middle file in the temporary directory that DITA-OT generates. It is usually named xxx_MERGED.xml (xxx is map file name).
  2. If you offer the merged middle file, we will extract only <indexterm> and generates index pages both usual method and dictionary based method.
  3. We will send you the both results and analyzing report with them in no charge.

Hope this helps your DITA publishing.

Regards,

-- 
/*----------------------------------------------------------------------- 
 Toshihiko Makita
 Development Group. Antenna House, Inc. Ina Branch
 E-Mail tmakita@...
 Web site:
 http://www.antenna.co.jp/
 http://www.antennahouse.com/
 ------------------------------------------------------------------------*/ 









Re: XSL-FO two-page layout

Jonathan Hanna
 

Hi Nick,

I publish my docs using a 5.5"x8.5" size (US-Statement) and then use Acrobat to print two pages on one printed page. Likewise, if you're using A4 paper, you can publish your document as an A5 size.

- Jonathan


Re: XSL-FO two-page layout

Toshihiko Makita
 

Hi Nick,

Although creating a two-column layout is simple enough, we're having difficult with the static content since it still shows one footer that spans the bottom of the page across the two columns.
Unfortunately AH Formatter does not support static contents per column. 
What content do you want to put into static contents? If it is only footnote, specifying axf:footnote-position="column" may be useful.

Regards,
-- 
/*----------------------------------------------------------------------- 
 Toshihiko Makita
 Development Group. Antenna House, Inc. Ina Branch
 Web site:
 http://www.antenna.co.jp/
 http://www.antennahouse.com/
 -----------------------------------------------------------------------*/



Re: XSL-FO two-page layout

David Hollis
 

Hi Nick,

From within Acrobat, go to File -> Properties -> Initial View

The Page layout drop down has 4 options for Two-Up layouts.

It might be possible to use XSL:FO to define a page layout? AH might have an extension to do this?

Alternatively, post process with an Acrobat Batch Script or JavaScript to change the page layout.

HTH,
David


Hi Mica,
That's it: page imposition.
We're using Antenna House.

How might you approach this instead?

On Monday, June 29, 2020, 10:17:10 AM PDT, Mica Semrick <mica@...> wrote:


Hey Nick,

Which PDF formatter are you using?

I think your approach might be off, as this generally isn't page level formatting. The feature is called "page imposition."

-m

On June 29, 2020 9:15:22 AM PDT, "Nicholas Mucks via groups.io" <urbanrobots@...> wrote:
Hello,
We're trying to create a two-page layout where each printed page has two pages on it.  Although creating a two-column layout is simple enough, we're having difficult with the static content since it still shows one footer that spans the bottom of the page across the two columns.

Has anyone created a PDF that displays two pages side by side in landscape orientation?

Thanks for your time.
- Nick


Re: Chapter numbering issue when using <topicgroup>

Chris Brand
 

Dear Toshihiko

I'm taking a bow. Your plugin works like a charm. Thank you very much for this nice feature!

That should be part of the DITA-OT by default.

Best regards
Chris.


Am 27.06.20 um 16:05 schrieb Toshihiko Makita:

Hi Chiris,

Sorry for the late reply.

As PDF2 plug-in has extension point named "org.dita.pdf2.xsl.topicmerge", you can override default topicmerge stylesheet processing by making plug-in.

Here is my example.

https://1drv.ms/u/s!AkbL99fLhxKUhp50UTIXM1xI7FSmlg?e=2Jrj9Q

You can integrate this plug-in and change PDF2 topicmerge processing. In my testing, I could succeed to remove topicgroup elements from the map portion of the merged middle file in DITA-OT 2.5.4.

If there are any problems, please let me know.

Regards,

-- 
/*----------------------------------------------------------------------- 
 Toshihiko Makita
 Development Group. Antenna House, Inc. Ina Branch
 Web site:
 http://www.antenna.co.jp/
 http://www.antennahouse.com/
 -----------------------------------------------------------------------*/


Re: XSL-FO two-page layout

Mica Semrick
 

It doesn't look like Antenna House supports imposition (correct me if I'm wrong!), so I'd consider another tool to do the imposition.

In prepress, imposition is usually done by the RIP or DFE, but those applications demand printing and are quite expensive.

Here is a good article about post processing post script (which antenna house can output) using pstops: https://wiki.scribus.net/canvas/How_to_make_impositions_with_pstops

Here is a script to do 2-up imposition with Ghostscript: https://stackoverflow.com/a/30546987

If you're looking for something radically different, a PDF producer called ConTeXt supports imposition and could (maybe?) replace Antenna House et al. It to s a different beast, not XML nor XSL FO, but it is quite flexible. https://wiki.contextgarden.net/Imposition

-m



On June 29, 2020 11:16:01 AM PDT, "Nicholas Mucks via groups.io" <urbanrobots@...> wrote:
Hi Mica,
That's it: page imposition.
We're using Antenna House.

How might you approach this instead?

On Monday, June 29, 2020, 10:17:10 AM PDT, Mica Semrick <mica@...> wrote:


Hey Nick,

Which PDF formatter are you using?

I think your approach might be off, as this generally isn't page level formatting. The feature is called "page imposition."

-m

On June 29, 2020 9:15:22 AM PDT, "Nicholas Mucks via groups.io" <urbanrobots@...> wrote:
Hello,
We're trying to create a two-page layout where each printed page has two pages on it.  Although creating a two-column layout is simple enough, we're having difficult with the static content since it still shows one footer that spans the bottom of the page across the two columns.

Has anyone created a PDF that displays two pages side by side in landscape orientation?

Thanks for your time.
- Nick


Re: XSL-FO two-page layout

Nicholas Mucks
 

Hi Mica,
That's it: page imposition.
We're using Antenna House.

How might you approach this instead?

On Monday, June 29, 2020, 10:17:10 AM PDT, Mica Semrick <mica@...> wrote:


Hey Nick,

Which PDF formatter are you using?

I think your approach might be off, as this generally isn't page level formatting. The feature is called "page imposition."

-m

On June 29, 2020 9:15:22 AM PDT, "Nicholas Mucks via groups.io" <urbanrobots@...> wrote:
Hello,
We're trying to create a two-page layout where each printed page has two pages on it.  Although creating a two-column layout is simple enough, we're having difficult with the static content since it still shows one footer that spans the bottom of the page across the two columns.

Has anyone created a PDF that displays two pages side by side in landscape orientation?

Thanks for your time.
- Nick

721 - 740 of 46291