Type | Description | |||
String | A string expression that indicates the padding of the caption in the panel. The list should be as "l t b r" where the l indicates the padding to left, t indicates the padding to top, and so on. For instance, "2 2 -2 -2" indicates that the text is padded 2 pixels from all sides. |
The following VB sample shows "How do I control the padding on the left, top or other sides":
With StatusBar1 .BeginUpdate .Debug = True .VisualAppearance.Add 4,"c:\exontrol\images\border.ebn" .VisualAppearance.Add 5,"CP:4 1 1 -1 -1" .BackColorPanels = 83886080 .BackColor = -2147483633 .Format = "1/2/(3,4)" With .Panel(3) .Text = "Arrange the panels as you want using CRD strings" .Alignment = exAlignTopLeft .ToolTipText = .Text .Offset = "10 10 -10 -10" End With .EndUpdate End WithThe following VB.NET sample shows "How do I control the padding on the left, top or other sides":
With AxStatusBar1 .BeginUpdate .Debug = True .VisualAppearance.Add 4,"c:\exontrol\images\border.ebn" .VisualAppearance.Add 5,"CP:4 1 1 -1 -1" .GetOcx().BackColorPanels = &H5000000 .GetOcx().BackColor = &H8000000f .Format = "1/2/(3,4)" With .get_Panel(3) .Text = "Arrange the panels as you want using CRD strings" .Alignment = EXSTATUSBARLib.TextAlignEnum.exAlignTopLeft .ToolTipText = .Text .Offset = "10 10 -10 -10" End With .EndUpdate End WithThe following C++ sample shows "How do I control the padding on the left, top or other sides":
/* Copy and paste the following directives to your header file as it defines the namespace 'EXSTATUSBARLib' for the library: 'ExStatusBar 1.0 Control Library' #import "C:\\WINNT\\system32\\ExStatusBar.dll" using namespace EXSTATUSBARLib; */ EXSTATUSBARLib::IStatusBarPtr spStatusBar1 = GetDlgItem(IDC_STATUSBAR1)->GetControlUnknown(); spStatusBar1->BeginUpdate(); spStatusBar1->PutDebug(VARIANT_TRUE); spStatusBar1->GetVisualAppearance()->Add(4,"c:\\exontrol\\images\\border.ebn"); spStatusBar1->GetVisualAppearance()->Add(5,"CP:4 1 1 -1 -1"); spStatusBar1->PutBackColorPanels(83886080); spStatusBar1->PutBackColor(-2147483633); spStatusBar1->PutFormat(L"1/2/(3,4)"); EXSTATUSBARLib::IPanelPtr var_Panel = spStatusBar1->GetPanel(long(3)); var_Panel->PutText(L"Arrange the panels as you want using CRD strings"); var_Panel->PutAlignment(EXSTATUSBARLib::exAlignTopLeft); var_Panel->PutToolTipText(var_Panel->GetText()); var_Panel->PutOffset(L"10 10 -10 -10"); spStatusBar1->EndUpdate();The following C# sample shows "How do I control the padding on the left, top or other sides":
axStatusBar1.BeginUpdate(); axStatusBar1.Debug = true; axStatusBar1.VisualAppearance.Add(4,"c:\\exontrol\\images\\border.ebn"); axStatusBar1.VisualAppearance.Add(5,"CP:4 1 1 -1 -1"); (axStatusBar1.GetOcx() as EXSTATUSBARLib.StatusBar).BackColorPanels = 0x5000000; (axStatusBar1.GetOcx() as EXSTATUSBARLib.StatusBar).BackColor = 0x8000000f; axStatusBar1.Format = "1/2/(3,4)"; EXSTATUSBARLib.Panel var_Panel = axStatusBar1.get_Panel(3); var_Panel.Text = "Arrange the panels as you want using CRD strings"; var_Panel.Alignment = EXSTATUSBARLib.TextAlignEnum.exAlignTopLeft; var_Panel.ToolTipText = var_Panel.Text; var_Panel.Offset = "10 10 -10 -10"; axStatusBar1.EndUpdate();The following VFP sample shows "How do I control the padding on the left, top or other sides":
with thisform.StatusBar1 .BeginUpdate .Debug = .T. .VisualAppearance.Add(4,"c:\exontrol\images\border.ebn") .VisualAppearance.Add(5,"CP:4 1 1 -1 -1") .BackColorPanels = 83886080 .BackColor = -2147483633 .Format = "1/2/(3,4)" with .Panel(3) .Text = "Arrange the panels as you want using CRD strings" .Alignment = 0 .ToolTipText = .Text .Offset = "10 10 -10 -10" endwith .EndUpdate endwith