Help Center

CTooltip.SetMarginmethod

Sets the top, left, bottom, and right margins for a Tooltip window.

WindowsmethodCTooltip.incdocumented

Syntax

SUB SetMargin (BYVAL hTooltip AS HWND, BYVAL lprc AS RECT PTR)
SUB SetMargin (BYVAL hTooltip AS HWND, BYREF rc AS RECT)
SUB SetMargin (BYVAL hTooltip AS HWND, BYVAL nLeft AS LONG, BYVAL nTop AS LONG, BYVAL nRight AS LONG, BYVAL nBottom AS LONG)

Parameters

NameDescription
hTooltipThe handle of the Tooltip control.
lprcPointer to a RECT structure that contains the margin information to be set. The members of the RECT structure do not define a bounding rectangle. For the purpose of this message, the structure members are interpreted as follows:
rcA RECT structure that contains the margin information to be set. The members of the RECT structure do not define a bounding rectangle. For the purpose of this message, the structure members are interpreted as follows:

Description

Sets the top, left, bottom, and right margins for a tooltip window. A margin is the distance, in pixels, between the tooltip window border and the text contained within the tooltip window.

Remarks

This message has no effect when the application runs on Windows Vista and visual styles are enabled for the tooltip. You can disable visual styles for the tooltip by using SetWindowTheme.

Reference

  • Include file CTooltip.inc
  • Defined in AfxNova/CTooltip.inc:567
  • Documented in Windows/WIndows Controls/CTooltip Class.md
  • Topic: CTooltip Class