rtLib — Notes Rich Text Management Library Documentation of rtLib — Notes Rich Text Management Library Download rtLib — Notes Rich Text Management Library FAQ of rtLib — Notes Rich Text Management Library Purchase rtLib — Notes Rich Text Management Library Feedback about rtLib — Notes Rich Text Management Library

Handling of Rich Text objects

Graphics, rulers and image resources

Start search Mail feedback Back to Description

Images use rtGraphic class. Although it allows to manipulate any image as a single object - resize, copy or delete, only JPEG and GIF images can be imported, exported or saved as image resource. The rtGraphic object allow to display either the images directly (equivalent of import or paste from client) or by referencing an image resource.

Set img = new rtGraphic("c:\temp\myimage.gif")

ctx.add img

' will create an image from file on disk.

img.saveAsResource "newres.gif", True ' will convert the imported image to image resource and reference the new resource instead of the image itself.

Set img = new rtGraphic("")

img.ResourceName = "newres.gif" ' reference resource

img.ResourceDesign.NoRefresh = True ' once we provide valid Image resource name, we may use ResourceDesign property of rtGraphic object to access design flags

img.PicHeight = img.PicHeight *1.2 ' set size to 120%; size changes proportionally unless we set property Proportional = False

Another useful graphical class is rtHRule. Mere ruler can be sized both horizontally and vertically, coloured simply or using colour gradient, thus forming multicolour bars of any dimension.

Set rule = new rtHRule (ONE_CM) ' provide height

Rule.RuleWidth = 5*ONE_CM

Set rule.Color = New rtColor(COLOR_BLUE) ' this will provide RGB color; we could also use property NotesColor to provide simple color index

Rule.Color.setAltRGB 128,128,0 ' set "To" color of gradient color

Rule.hasGradient = True