How to get and set TextNode element's size and font?

I tried a lot of way to do that,but still failed.

TextNode element has not got the width,height and font properties.

Who can help? Thanks.

 

Parents
  • TextElement vs. TextNodeElement

    spike:

    TextNodeElement has not got the width, height or font properties.

    A TextNodeElement is not a TextElement. A TextNodeElement is a container of TextElements. TextElements have properties concerning appearance and contain the text that you see in graphics.

    You need to enumerate the TextElements contained in the TextNodeElement, and set the symbology for each TextElement that you find. Lookup GetSubElements in VBA help.

    Regards, Jon Summers
    LA Solutions

     
    Regards, Jon Summers
    LA Solutions

  • Unknown said:
    A TextNodeElement is not a TextElement. A TextNodeElement is a container of TextElements. TextElements have properties concerning appearance and contain the text that you see in graphics.

    TextNodeElement also has formatting properties, even when there is no text in it.

    Just add a new text node in the GUI, then look at its Element properties,
    When one adds some text to the textnode, these properties are inherited, but the text node still has a sepate formatting - one can inspect the file with OpenDGN to see that.

    So the remaining question is how to reach these properties through the Microstation API.
    Or is it some deprecated feature of DGN V7 that is deliberately made inaccessible?

Reply
  • Unknown said:
    A TextNodeElement is not a TextElement. A TextNodeElement is a container of TextElements. TextElements have properties concerning appearance and contain the text that you see in graphics.

    TextNodeElement also has formatting properties, even when there is no text in it.

    Just add a new text node in the GUI, then look at its Element properties,
    When one adds some text to the textnode, these properties are inherited, but the text node still has a sepate formatting - one can inspect the file with OpenDGN to see that.

    So the remaining question is how to reach these properties through the Microstation API.
    Or is it some deprecated feature of DGN V7 that is deliberately made inaccessible?

Children