memoHints lacks a Transparent property and looks ugly in XP theming where the pages of a pagecontrol normally have a different color than clBtnFace. Convert the TMemo to a TLabel and set that to transparent.

This commit is contained in:
Ansgar Becker
2008-05-12 08:07:12 +00:00
parent 2688c224a4
commit b095a2abb2
2 changed files with 22 additions and 33 deletions

View File

@ -161,6 +161,18 @@ object UserManagerForm: TUserManagerForm
ParentFont = False
WordWrap = True
end
object lblHints: TLabel
Left = 10
Top = 86
Width = 382
Height = 78
Alignment = taRightJustify
Anchors = [akLeft, akTop, akRight]
AutoSize = False
Caption = 'lblHints'
Enabled = False
WordWrap = True
end
object editPassword: TEdit
Left = 100
Top = 33
@ -193,35 +205,6 @@ object UserManagerForm: TUserManagerForm
Text = 'editUsername'
OnChange = editUsernameChange
end
object memoHints: TMemo
Left = 10
Top = 86
Width = 382
Height = 78
Alignment = taRightJustify
Anchors = [akLeft, akTop, akRight]
BevelInner = bvNone
BevelOuter = bvNone
BorderStyle = bsNone
Color = clBtnFace
Enabled = False
Lines.Strings = (
'(Host: % and _ wildcards allowed)'
'(Host: <ip>/<full netmask> syntax ok)'
'(Host: server skips name resolve?: $SNR)'
'(Note: When no account match during login, the Everybody account' +
' is tried.)'
'(Note: If multiple accounts match, the first account in sorted o' +
'rder is tried.)'
'(Note: After login, privileges are given based on ALL accounts t' +
'hat match.)')
ReadOnly = True
TabOrder = 4
WordWrap = False
end
object chkDisabled: TCheckBox
Left = 8
Top = 83

View File

@ -162,7 +162,7 @@ type
editUsername: TEdit;
lblLimitHint: TLabel;
lblWarning: TLabel;
memoHints: TMemo;
lblHints: TLabel;
panelVista1: TPanel;
tlbUsers: TToolBar;
btnAddUser: TToolButton;
@ -226,14 +226,20 @@ var
}
procedure TUserManagerForm.FormCreate(Sender: TObject);
var
snr: String;
snr, Hints: String;
begin
Width := Mainform.GetRegValue(REGNAME_USERMNGR_WINWIDTH, Width);
Height := Mainform.GetRegValue(REGNAME_USERMNGR_WINHEIGHT, Height);
db := Mainform.Mask(DBNAME_MYSQL);
Hints := '(Host: % and _ wildcards allowed)'+CRLF+
'(Host: <ip>/<full netmask> syntax ok)'+CRLF+
'(Host: server skips name resolve?: $SNR)'+CRLF+
'(Note: When no account match during login, the Everybody account is tried.)'+CRLF+
'(Note: If multiple accounts match, the first account in sorted order is tried.)'+CRLF+
'(Note: After login, privileges are given based on ALL accounts that match.)';
snr := Mainform.Childwin.GetVar('SHOW VARIABLES LIKE ' + esc('skip_name_resolve'), 0, True, False);
if snr = '' then snr := 'Unknown';
memoHints.Text := TrimRight(StringReplace(memoHints.Text, '$SNR', snr, []));
lblHints.Caption := StringReplace(Hints, '$SNR', snr, []);
end;
@ -469,7 +475,7 @@ begin
editPassword.Enabled := Enable;
lblFromHost.Enabled := Enable;
editFromHost.Enabled := Enable;
memoHints.Enabled := Enable;
lblHints.Enabled := Enable;
chkDisabled.Enabled := Enable;
// Update controls in Limitations tab
lblMaxQuestions.Enabled := Enable;