Forum Replies Created

  • Derek Read

    Reply To: Image element sizing question

    Participants 0
    Replies 2618
    Last Activity 12 years ago

    I see. The only one of those three types (ISO, CGM, TIFF) that is natively supported is TIFF, however, scaling that will require implementing one or more of three attributes for the element: something for width, something for height and/or something for scale. The last one is used by XMetaL Author for our DITA solution but not documented in the Programmer's Guide yet nor is it editable in the XMetaL Developer CTM editor yet, so it would need to be coded by hand using a text editor. For an example see the setting “Scale-Attribute” in this file in XMetaL Author Enterprise 5.1: C:Program FilesXMetaL 5.1AuthorDITAXACstopictopic_ditabase.ctm

    The other two image types will require embedding ActiveX controls and in that case (as noted earlier in this thread) you can control the size of the control using script.

    Reply

    Derek Read

    Reply To: How to hide attributes in inspector with XMetaL Author DITA 5.1?

    Participants 0
    Replies 2618
    Last Activity 12 years ago

    Both suggestions posted so far are good but here are some thoughts in how they differ:

    Note that the script example posted by S. Strube modifies the element list, not the Attribute Inspector. You could create a similar script to hide specific attributes. In this case it should only be necessary to have such a script run at document open. Here is an example:
    [code]


    hideAttrs_945D183765F14();
    ]]>

    //Note: function name chosen to be unique to avoid potential conflicts
    function hideAttrs_945D183765F14() {
    var attrsToHide = new Array(“base”, “props”, “xml:lang”, “dir”, “translate”, “platform”, “product”); //loop through the list and hide the attributes
    for (i=0;i ActiveDocument.HideInAttributeInspector(attrsToHide);
    }
    }
    ]]>

    [/code]

    Placing an MCR file containing the code above into the Startup folder should give you what you want. Removing it will restore the default behaviour.

    Note that making scripting modifications to the DITA customization beyond adding functionality as described in the file [C:Program FilesXMetaL 5.1AuthorDITAXACsditabaseditabase_ditabase.off.js] is not officially supported. If you upgrade to a newer version you will need to check that any scripts you added still function and modify them to continue working with any new functionality we might introduce. Basically we can't guarantee that we won't modify portions of the DITA system in the same way that we do try to guarantee that all of our XMetaL Author APIs as documented in the Programmer's Guide will be backward compatible between releases.

    Also note that as written the script above will affect all DTDs and Schemas, not just DITA. So, if you are using other DTDs and they have similar attributes, and you do not wish to hide those attributes the script will either need to be modified to detect which DTD is loaded or turned into a document-level customization script for each DTD you wish it to affect.

    The main limitation with this scripting approach is that it only hides these attributes in the Attribute Inspector. It does not stop someone from adding them in PlainText view, nor does it hide them from any of the dialogs provided for editing attributes in DITA documents. It will also not stop users from pasting XML content from other sources containing these attributes into a document. These things may or may not be desirable (the original purpose for hiding them was not described).

    If they are not desirable and you wish to stop people from ever using these attributes then you will need to follow Su-Laine's recommendation and create a specialized DTD that has the attributes removed.

    Reply

    Derek Read

    Reply To: Image element sizing question

    Participants 0
    Replies 2618
    Last Activity 12 years ago

    It isn't clear to me if scaling images is necessary for your customization.

    If scaling is not a requirement, and your images are a supported type of bitmap (JPG, GIF, BMP, etc) then XMetaL Author renders them at their “default” size (1 pixel = 1 pixel).

    Reply

    Derek Read

    Reply To: How to change table width?

    Participants 0
    Replies 2618
    Last Activity 12 years ago

    To answer this question easily we need to know the following:

    Which DTD or Schema are you working with? (this is why people are asking about “DITA”)

    Which table model does the DTD use? XMetaL supports HTML, CALS, and “semantic” tables.

    Are you asking about modifying the width during editing or in output?

    The first two have official specs (HTML at W3C and CALS at OASIS) and XMetaL Author allows you to modify the width for both of these very easily during editing through the user interface, either by dragging borders or using the Table Properties dialog, provided your DTD or Schema defines these tables using the proper attributes to support this.

    Semantic tables are any group of elements you have customized (usually using XMetaL Developer) to render as a table using CSS settings. The width of semantic tables is automatically determined by the content it contains, but will not render larger than the width of the current editing width of the document containing it.

    When producing output the width of tables is defined directly as a result of the process used to generate that output in combination with the XML being passed to that process. The transformation process might use XSLT, XSLT + XSL-FO, or some other method. So, knowing the table type is important, knowing which tool you are using to generate output is important, as well as the type of output you are producing.

    If you are working with DITA documents then we might assume you are using the DITA Open Toolkit that is integrated with XMetaL Author Enterprise. In that case we still need to know which type of output you are attempting to produce.

    Reply

    Derek Read

    Reply To: Table – Merging Multiple Cells

    Participants 0
    Replies 2618
    Last Activity 12 years ago

    The product simply does not have this feature. We may add it in the future.

    Reply

    Derek Read

    Reply To: Customer expects some initial response from XMetaL experts at JustSystem

    Participants 0
    Replies 2618
    Last Activity 12 years ago

    We don't have an official policy for answering postings here. The main thing we hope to accomplish by hosting this forum is to provide a location for users of XMetaL products to discuss issues and share ideas. Many JustSystems employees are members of this forum but I would not want to say they have any official obligations to provide answers here. This  includes members of the XMetaL Support team whose primary focus must be to continue to support clients that submit cases via the normal support channels.

    That having been said, everyone at JustSystems is very interested in seeing the forum succeed and whenever we have good information to share, and time to share it, we will be posting here.

    If you see no responses from employees of JustSystems then you can probably assume nobody has an answer for your problem, or that people have not had time to answer. We encourage all forum members to respond to postings. We think many XMetaL users would like to use the forums as an opportunity to network with each other and to develop a sense of community. There are lots of members on this forum that have many years of experience with the XMetaL product line.

    If you do need an immediate response to a problem please log a case through the JustSystems regular support channels. Keep in mind that XMetaL Support is not mandated to provide scripts, specific solutions, help debug customizations, etc. They try to provide workarounds to bugs in out-of-the-box features and where no workaround is possible they file bug reports with the development team, to be addressed in a future release. They also take feature requests for possible inclusion in future releases, try to answer questions when documentation is ambiguous, and may suggest various ways of accomplishing certain tasks.

    The forum is also a place for the XMetaL Support team to post answers to questions asked through the regular support channels (after first having helped the particular client directly). We expect other JustSystems employees that have useful information to be sharing it as well. For some examples see the XMetaL Tips and Tricks board.

    If you need a specific solution to a problem that requires customization work JustSystems has a professional services team that can be hired on a contractual basis. Your XMetaL sales contact can walk you through that process (contracts, statements of work, price quotes, etc).

    Reply

    Derek Read

    Reply To: Looking for Script to toggle capitalization

    Participants 0
    Replies 2618
    Last Activity 12 years ago

    I happen to have such a demo script. I will post it when I get a moment to clean it up and place it in the XMetaL Tips and Tricks section.

    It may not do exactly what you are asking for here, but it would probably at least get you started.

    Reply

    Derek Read

    Reply To: Script Example: Word Count Feature

    Participants 0
    Replies 2618
    Last Activity 12 years ago

    I think in the case of xml content, this is a task I would put in the xslts rather than the editor.

    The requirement this script attempts to help with is the need some people have to count the number of words in the document they are currently writing (for whatever reason) at any point without needing to save or do any kind of transform. This provides one solution that is extremely easily to integrate as it is done purely via script and relies completely on JScript with no need for any external parsing engines. Here are some benefits to this method:

    1. Script is very simple and easy to understand.
    2. Script runs very fast because it uses pure string manipulation methods built into JScript engine and does not require interaction with an external control (such as XSLT engine) or XMetaL Author
    APIs (which would be needed for a DOM manipulation solution).
    3. Works the same for all schema (due to the simplistic definition of what a “word” is). Some would argue this is exactly where the script falls down (it really depends on your needs).

    Those things having been said, if anyone else can improve on what's been posted here and make it easily integrated into XMetaL Author I'm sure others would like to see what you've done. In future examples I will try to clearly state what problem an example is trying to solve to make things clear.

    The most obvious limitation with this script is the simplified definition it uses for “word”. For the vast majority of people that just want a rough estimate this script is likely good enough. As others have stated though, using XSLT or DOM calls could be more accurate, though that would depend on your needs as well as the schema you are using. I don't think a truly accurate solution can be made to work for all schema though, and in many cases (as hinted at by mag3737) building an intimate knowledge of a particular schema into the solution may be required to provide a truly accurate word count, and that means such a solution will not work for all schema.

    Reply

    Derek Read

    Reply To: Decorating CSS Content

    Participants 0
    Replies 2618
    Last Activity 12 years ago

    You can do this type of thing:

    section0:before {
      content: “0 – GENERALITES – CARACTERISTIQUES”;
      font-family: “Courier New”;
      font-size: 2em;
      color: #00F;
      display: block;
      border: 1px solid red;
    }

    That styling is separate from the associated selector (section0 by itself).

    Reply

Products
Downloads
Support