Leadtools.Annotations Requires Document/Medical product license | Send comments on this topic. | Back to Introduction - All Topics | Help Version 16.5.9.25
AnnTextRollupObject Class
See Also  Members   Example 
Leadtools.Annotations Namespace : AnnTextRollupObject Class



This class provides support for creating and managing text rollup annotation objects.

Object Model
















Syntax

Visual Basic (Declaration) 
<SerializableAttribute()>
Public Class AnnTextRollupObject 
   Inherits AnnNoteObject
   Implements IAnnTextObject 
Visual Basic (Usage)Copy Code
Dim instance As AnnTextRollupObject
C# 
[SerializableAttribute()]
public class AnnTextRollupObject : AnnNoteObject, IAnnTextObject  
C++/CLI 
[SerializableAttribute()]
public ref class AnnTextRollupObject : public AnnNoteObject, IAnnTextObject  

Example

This example creates a new text rollup object.

Visual BasicCopy Code
Private Sub AnnTextRollupObject_AnnTextRollupObject(ByVal viewer As RasterImageViewer, ByVal container As AnnContainer)
   Dim textRollup As AnnTextRollupObject = New AnnTextRollupObject()
   textRollup.Text = "My TextRollup object"
   textRollup.Font = New AnnFont("Arial", New AnnLength(10, AnnUnit.Point), FontStyle.Regular)
   textRollup.EdgeMargin = AnnLength.Empty
   textRollup.ShadowBorderWidth = New AnnLength(6, AnnUnit.Pixel)
   textRollup.Alignment = StringAlignment.Center
   textRollup.LineAlignment = StringAlignment.Center
   textRollup.Bounds = New AnnRectangle(100, 200, 400, 600, AnnUnit.Pixel)
   container.Objects.Add(textRollup)
   textRollup.Expanded = False
   viewer.Invalidate(textRollup.InvalidRectangle)
   MessageBox.Show("Not expanded")

   textRollup.Expanded = True
   viewer.Invalidate(textRollup.InvalidRectangle)
   MessageBox.Show("expanded")
End Sub
C#Copy Code
private void AnnTextRollupObject_AnnTextRollupObject(RasterImageViewer viewer, AnnContainer container) 

   AnnTextRollupObject textRollup = new AnnTextRollupObject(); 
   textRollup.Text = "My TextRollup object"; 
   textRollup.Font = new AnnFont("Arial", new AnnLength(10, AnnUnit.Point), FontStyle.Regular); 
   textRollup.EdgeMargin = AnnLength.Empty; 
   textRollup.ShadowBorderWidth = new AnnLength(6, AnnUnit.Pixel); 
   textRollup.Alignment = StringAlignment.Center; 
   textRollup.LineAlignment = StringAlignment.Center; 
   textRollup.Bounds = new AnnRectangle(100, 200, 400, 600, AnnUnit.Pixel); 
   container.Objects.Add(textRollup); 
   textRollup.Expanded = false; 
   viewer.Invalidate(textRollup.InvalidRectangle); 
   MessageBox.Show("Not expanded"); 
 
   textRollup.Expanded = true; 
   viewer.Invalidate(textRollup.InvalidRectangle); 
   MessageBox.Show("expanded"); 
}

Remarks

The text rollup annotation object extends AnnNoteObject by adding an Expanded property. When this property is set to false, the text rollup object looks and behaves like a normal note. When Expanded is set to false, the text rollup object will shrink to show only one line of text. This saves space on the container surface. For more information, refer to Using Text in Annotation Object. For more information about the text rollup annotation object refer to AnnTextRollupObject. For more information about the automated text rollup annotation object, refer to Annotation Objects - Automated Features.

Inheritance Hierarchy

System.Object
   Leadtools.Annotations.AnnDrawable
      Leadtools.Annotations.AnnObject
         Leadtools.Annotations.AnnRectangleObject
            Leadtools.Annotations.AnnTextObject
               Leadtools.Annotations.AnnNoteObject
                  Leadtools.Annotations.AnnTextRollupObject

Requirements

Target Platforms: Microsoft .NET Framework 3.0, Windows XP, Windows Server 2003 family, Windows Server 2008 family

See Also

Leadtools.Annotations requires a Document or Medical toolkit license and unlock key. For more information, refer to: Imaging Pro/Document/Medical Features