TX Text Control ActiveX

What's New in TX Text Control ActiveX 12.0

Topic

TX Text Control ActiveX 12.0 introduced text frames and images anchored to a paragraph, which move with the text around them. A dialog box and a mouse interface for images and text frames, and more control over tables at page breaks, came with them.

Here are the features, the new members and the update notes of version 12.0 since version 11.0.

New Features

  • Anchored images. In earlier versions, images and OLE objects were either inserted like a single character or positioned geometrically relative to the complete document. Version 12.0 adds a third method, anchored to a paragraph: the text still flows around the image or OLE object, but its geometrical position is relative to the paragraph it is anchored to. If text is inserted in front of this paragraph, the object moves with the text. The new ImageInsert and ObjectInsert methods insert such an image or OLE object, and all properties for images and OLE objects were enhanced so that your code can work with anchored images and OLE objects.
  • Text frames. A text frame is a rectangle that users fill with text and edit like the main text. It is positioned like an image, either geometrically or as a single character; geometrically, its position is relative either to the paragraph it is anchored to or to a page of the document. Three methods insert text frames: TextFrameInsert inserts a text frame anchored to a paragraph, which moves with the text, TextFrameInsertAsChar inserts a text frame that the document handles like a single character, and TextFrameInsertFixed inserts a text frame at a fixed position on the page.
  • Text frames in code. Text frames are fully programmable: every property and method of TXTextControl can be routed to a text frame. The new TextFrameSelect method determines whether a property works on a text frame or on the main text. Further properties set the attributes of a text frame, such as the width of the border line, the internal margins and the background color.
  • Image and text frame attributes. A new built-in dialog box changes the attributes of images and text frames. It sets general attributes such as size, text wrapping, scaling and text distances. A special tab sets the file name, format, resolution and compression for image export, and another sets the background color and frame attributes of text frames. The new ObjectAttrDialog method opens this dialog box.
  • Mouse interface for images and text frames. Users move and size integrated objects such as images and text frames with the mouse, in every insertion mode. A selection frame with sizing handles shows whether an object is selected.
  • Table formatting. Users get more control over how tables are formatted at page breaks. CTRL+ENTER inserts a forced page break in a table at any character position, which moves the complete table row to the next page. A table row can have a formatting attribute that moves the complete row to the next page if at least one line of its text is on the next page. A table row can also have a minimum height, and it grows as needed when more text is inserted. All of these features are set in the built-in dialog box for table attributes and in code with the TableCellAttribute property.

New Properties, Methods and Events

Properties

MemberDescription
TXTextControl.HeaderFooterAtInputPosReturns the header or footer that owns the current text input position.
TXTextControl.ObjectHeightReturns or sets the natural height, in twips, of an image, text frame, signature field or OLE object.
TXTextControl.ObjectWidthReturns or sets the natural width, in twips, of an image, text frame, signature field or OLE object.
TXTextControl.TextFrameBackColorReturns or sets the background color of a text frame.
TXTextControl.TextFrameBorderWidthSpecifies the width, in twips, of the border line of a text frame.
TXTextControl.TextFrameInternalMarginSpecifies the distance, in twips, between the border line of a text frame and its text.
TXTextControl.TextFrameMarkerLinesDetermines whether marker lines for text frames are visible.

Methods

MemberDescription
TXTextControl.ImageInsertInserts a new image anchored to a paragraph.
TXTextControl.ImageInsertAsCharInserts a new image, which the text then handles like a single character.
TXTextControl.ImageInsertFixedInserts a new image at a fixed geometrical position.
TXTextControl.ObjectAttrDialogOpens the built-in dialog box that sets the attributes of images, text frames and OLE objects.
TXTextControl.ObjectGetSelectedReturns the identifier of the currently selected object.
TXTextControl.ObjectInsertInserts a new OLE object or other control anchored to a paragraph.
TXTextControl.TextFrameInsertInserts a new text frame anchored to a paragraph.
TXTextControl.TextFrameInsertAsCharInserts a new text frame, which the text then handles as a single character.
TXTextControl.TextFrameInsertFixedInserts a new text frame at a fixed geometrical position.
TXTextControl.TextFrameSelectDetermines whether a property or method of TXTextControl works on a text frame or on the main text.

Events

MemberDescription
TXTextControl.ObjectRightClickedOccurs when an object has been clicked with the right mouse button.
TXTextControl.TextFrameActivatedOccurs when a text frame has received the input focus.
TXTextControl.TextFrameDeactivatedOccurs when a text frame has lost the input focus.

Update Notes

MemberUpdate note
ObjectCurrent propertyExtended to support text frames and anchored images and OLE objects.
ObjectNext methodExtended to support text frames and anchored images and OLE objects.