#include "l_bitmap.h"
L_LTANN_API L_INT L_AnnSetLineFixedWidth (hObject, bLineFixedWidth, uFlags)
Sets a value that indicates whether the line width changes with scaling.
Handle to the annotation object.
Flag that indicates whether the line width changes with scaling. Possible values are:
Value | Meaning |
---|---|
TRUE | The line width does not change with scaling. |
FALSE | The line width changes with scaling. This is the default value. |
Flags that determine which objects to process. Most of the flags apply only to container objects. You can combine values when appropriate by using a bitwise OR ( | ). Possible values are:
Value | Meaning |
---|---|
0 | Process only the specified object. |
ANNFLAG_SELECTED | [0x0001] Process only objects that have the selected property set to TRUE. For getting and setting the selected property, call the L_AnnGetSelected and L_AnnSetSelected functions. |
ANNFLAG_NOTTHIS | [0x0004] Process only one level of objects within the specified container, not the container itself. If there are containers within the container, they are modified, but the objects within them are not. |
ANNFLAG_RECURSE | [0x0008] Process objects within a container, and within any sub containers, down to any level. |
ANNFLAG_NOTCONTAINER | [0x0002] (Used with ANNFLAG_RECURSE) Process objects within containers, not the containers themselves. |
ANNFLAG_NOINVALIDATE | [0x0010] Do not invalidate the affected rectangle in the window. Use this to avoid generating unwanted paint messages. |
ANNFLAG_CHECKMENU | [0x0020] Process objects only if the ANNAUTOTEXT_MENU_LINE menu item has been selected. |
Value | Meaning |
---|---|
SUCCESS | The function was successful. |
< 1 | An error occurred. Refer to Return Codes. |
The line width of an object is relative to its container object, and the value is interpreted using the container's scaling factors. As a result, when zooming in the line width increases, and when zooming out the line width decreases. This is the default behavior.
In some cases it might be preferable to have the line width of an annotation object remain constant, regardless of the scaling (zooming). To do this, call L_AnnSetLineFixedWidth function with the bLineFixedWidth
parameter set to TRUE.
This function does not affect objects that do not have this property or that do not let you change the property. For more information on the objects types and their properties, refer to Types of Annotations.
Required DLLs and Libraries
Win32, x64.
This examples toggles the line fixed width setting of the annotation object (hObject)
L_INT AnnSetLineFixedWidthExample(HANNOBJECT hObject)
{
L_INT nRet = TRUE;
L_BOOL bLineFixedWidth = FALSE;
L_TCHAR szMsg[200];
nRet = L_AnnGetLineFixedWidth (hObject, &bLineFixedWidth);
if (nRet != SUCCESS)
return nRet;
bLineFixedWidth = !bLineFixedWidth;
nRet = L_AnnSetLineFixedWidth(hObject, bLineFixedWidth, 0);
if (nRet != SUCCESS)
return nRet;
wsprintf(szMsg, _T("bLineFixedWidth changed from %s to %s"),
!bLineFixedWidth ? _T("TRUE") : _T("FALSE"),
bLineFixedWidth ? _T("TRUE") : _T("FALSE"));
MessageBox(NULL, szMsg, _T("Notice"), MB_OK);
return nRet;
}
Help Collections
Raster .NET | C API | C++ Class Library | HTML5 JavaScript
Document .NET | C API | C++ Class Library | HTML5 JavaScript
Medical .NET | C API | C++ Class Library | HTML5 JavaScript
Medical Web Viewer .NET
Multimedia
Direct Show .NET | C API | Filters
Media Foundation .NET | C API | Transforms
Supported Platforms
.NET, Java, Android, and iOS/macOS Assemblies
Imaging, Medical, and Document
C API/C++ Class Libraries
Imaging, Medical, and Document
HTML5 JavaScript Libraries
Imaging, Medical, and Document