Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
0

Problems with image attributes

Explorer ,
Jun 16, 2011 Jun 16, 2011

Copy link to clipboard

Copied

I'm not a native speaker but I give it a try 🙂

I tried to add attributes of my image element directly in the attributes window, for example I set the alignment to left. But the image is then still aligned center and it won't save the setting when I save the xml file. I looked throw my dtd and also the r/w rules but they are seem to be ok.

When I set the attributes in the anchored frame window everything works just fine.

My DTD looks like these (BildPosition is the alignment, BildAusrichtung is the position of the image):

<!ATTLIST Bild       src       CDATA     #IMPLIED
                     BildPosition  (below)   #IMPLIED
                     BildAusrichtung  (left)    #IMPLIED

...

--------

My r/w rules are these one:

/* Graphic element: Bild */
element "Bild" {
is fm graphic element;
writer facet default
{
specify size in cm;
}

fm property import by reference or copy value is "ref";

attribute "src"
{
is fm attribute "src";
is fm property file;
}
  attribute "BildPosition" {
    is fm attribute "BildPosition";      
    is fm property position;
     }

    attribute "BildAusrichtung" {
    is fm attribute "BildAusrichtung";
    is fm property alignment;
    value "left" is fm property value align left;
     }

....

------------

Has anyone an idea what I do wrong?

Thanks!

TOPICS
Structured

Views

721
Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Advocate ,
Jun 16, 2011 Jun 16, 2011

Copy link to clipboard

Copied

Hello Dokuteam1,

If you’s prefer help from colleagues in German you might want to use one of the resources listed here: https://groups.google.com/forum/#!forum/frameusers-de

There is no way to control the anchoring position or image alignment just by changing attribute values. Both properties are native FrameMaker properties and with the correct R/W rules they can be written to XML and read, but there is no way to control their setting via the EDD.

My solution for tasks like this is an event script, which »listens« to attribute changes. If one of those attribute values is changed I make the native FrameMaker setting via the script. E.g. if you would change your attribute BildPosition from "below" to "inline" the script would kick in an make the change as if you would have made it yourself in the Anchored Frame dialog. This of course requires FrameScript or FrameMaker 10 (with ExtendScript) or an FDK plug-in.

- Michael Müller-Hillebrand

Votes

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Jun 17, 2011 Jun 17, 2011

Copy link to clipboard

Copied

Hi,

thanks for the tip with the german forum.

I wonder why this worked with DITA. When I create a normal DITA topic out of the menu I can change the attributes. Is there a script behind?

Thanks.

Greetings.

Votes

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Advocate ,
Jun 17, 2011 Jun 17, 2011

Copy link to clipboard

Copied

Am 17.06.2011 um 09:16 schrieb Dokuteam1:

I wonder why this worked with DITA. When I create a normal DITA topic out of the menu I can change the attributes. Is there a script behind?

You did not mention the FrameMaker version you are working with, nor the DITA implementation you are talking about (Adobe-DITA, or DITA-FMx by Leximation). So it is hard to guess anything…

- Michael Müller-Hillebrand

Votes

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Jun 17, 2011 Jun 17, 2011

Copy link to clipboard

Copied

Sorry,

I am using FM 10. I created my own DTD and r/w rules (not for DITA). After the alignment of anchored frame not worked out, I make a DITA topic (Adobe DITA) out of the menu to try if it workes there and it worked with DITA.

Greetings.

Votes

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guide ,
Jun 17, 2011 Jun 17, 2011

Copy link to clipboard

Copied

When I set the attributes in the anchored frame window everything works just fine.
There is no way to control the anchoring position or image alignment just by changing attribute values. Both properties are native FrameMaker properties and with the correct R/W rules they can be written to XML and read, but there is no way to control their setting via the EDD.

There was another long thread in this forum about this issue; however, I cannot find it.

The point is that once you open an XML file in FrameMaker, you cannot change properties of certain FrameMaker objects by changing the attributes in the corresponding element. You have to change the properties via the objects themselves. Thus, for graphics in anchored frames, you select the graphic and change its properties (Object Properties) the same as you do in unstructured FrameMaker. Also, you can select the anchored frame and change its properties the same way you do in unstructured FrameMaker.

Then with the correct read/write rules, those object properties are exported as attribute values in the XML. When you open the XML in FrameMaker, the attribute values are converted to the corresponding FrameMaker objects. You can find all the information about this in the FrameMaker Structured Applications Guide.

Thus, there is no need for a script, unless you really want the ability to change FrameMaker object properties via changing attribute values.

Van

Votes

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Jun 17, 2011 Jun 17, 2011

Copy link to clipboard

Copied

LATEST

Ok, thank you very much. I think I will then use the object properties to change the attributes.

Votes

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines