DITA and XMetaL Discussion

XMetaL Community Forum DITA and XMetaL Discussion Highlighting Text and Applying User Interface Style Works…Sometimes

  • dianamost

    Highlighting Text and Applying User Interface Style Works…Sometimes

    Participants 0
    Replies 1
    Last Activity 13 years, 6 months ago

    Wondering if anyone else has this problem…..and has found a solution!

    We are using XMetal 5.5 with DITA.  Sometimes when I apply a style to existing text, the results are not what I expect.

    With the User Interface Element, I can select existing text and then select Insert > User Interface Element > Uicontrol to apply the existing text tags without wiping out the text.  It works most of the time.

    However, if I try the same thing with Insert > User Interface Element > Menu Cascade, it erases the existing text and inserts the blank command. 

    This means I am retyping dozens of single menu items that I did not apply the style to when I created them. I didn't know at the time that I had to use the menu cascade because there is no second menu. The Menu Cascade style has to be there to comply with our standards because it has special font formatting.

    Does it wipe out my text because of the “?xm-replace_text UI Control?” command in the inserted XML? Is there another way of doing this without losing my text? An easier way to do it? 

    Thanks in advance.
     

    Reply

    Derek Read

    Reply to: Highlighting Text and Applying User Interface Style Works…Sometimes

    This is not you, this is a limitation in the software. It always occurs for because we do not have any code that attempts to preserve what is currently selected in this case. I assume we will try to correct this at some point.

    There are two workarounds I can think of for the 5.1 and 5.5 releases:

    Using the Insert Menu:
    Assuming you have something like this:
    [code]

    text1 text2 text3

    [/code]
    1. Select each of text1, text2, text3 in turn and select “User Interface Control” from the Insert menu.
    2. Place your insertion point before all of the first elements you just inserted and select Menu Cascade from the Insert menu. You should now have the following (carriage returns added for clarity here):
    [code]

     
     
    text1
    text2
    text3

    [/code]
    3. Select all of the items, press Ctrl+X to cut them.
    4. Select all of the
    elements inside and press Ctrl+V to paste over them. You will end up with this:
    [code]

    text1
    text2
    text3

    [/code]

    Using the Element List:
    Assuming you have something like this:
    [code]

    textitem1 textitem2 textitem3

    [/code]

    1. Select each of textitem1, textitem2, textitem3 in turn and double click on the element in the Element List. You will then have this:
    [code]

    text1
    text2
    text3

    [/code]
    2. Select all of the elements you just inserted and then double click on in the Element List. You will then have this:
    [code]

    text1
    text2
    text3

    [/code]

    Reply

  • You must be logged in to reply to this topic.

Lost Your Password?

Products
Downloads
Support