TextHint with a TwwController



  • Roy Woll

    I cannot reproduce your problem. Although the hint property should be named Hint and not TextHint. You also should have ShowHint set to true.

    Comment actions Permalink
  • Frontline Software

    TextHint (https://docwiki.embarcadero.com/Libraries/Alexandria/en/Vcl.StdCtrls.TEdit.TextHint)


    For dbedit controls it only displays when in edit/insert mode, and it works fine for Woll2Woll as long as it's not hooked up to a controller.

    Comment actions Permalink
  • Roy Woll

    I think the problem is when the border style =bsnone, then it will not show.  Our controls do not paint this themselves but when borderstyle=bsnone, they enable the es_multiline style attribute to properly position the text within the control, which I am guessing does not support texthint. I'm not sure of a way around this unless you don't use framing.


    From looking at our source in vcl.wwdbedit.pas, if you comment out the line that sets es_multiline it will show the hint.

    procedure TwwCustomMaskEdit.CreateParams(var Params: TCreateParams);
      inherited CreateParams(Params);
      Params.Style := Params.Style and not (ES_AUTOVSCROLL or ES_WANTRETURN);
    //  if (BorderStyle = bsNone) or WordWrap then
    // Params.Style:= Params.Style or ES_MULTILINE;
      if WordWrap then Params.Style :=
    (Params.Style or ES_AUTOVSCROLL) and not ES_AUTOHSCROLL;
      if FWantReturns then Params.Style:=
    Params.Style or ES_WANTRETURN;
      if FShowVertScrollBar then
    Params.Style:= Params.Style or WS_VSCROLL;


    Comment actions Permalink

Please sign in to leave a comment.

Powered by Zendesk