Is it possible to have a Multiline TextField?

It really changes the look and feel of and app having properly themed controls.

Imagine if the IDE also have good looking multiline Textfields and Properly themed TextAreas…

Until xojo fixes this, if womeone is interested on having a better look in your app:

  • Fixing the padding:

#If TargetWindows Then
  
  Declare Sub GetClientRect Lib "User32" (handle As Integer, r As Ptr)
  Declare Sub InflateRect Lib "User32" (r As Ptr, dx As Int32, dy As Int32)
  Declare Function SendMessageA Lib "User32" (hWnd As Integer, Msg As Integer, wParam As Integer, lParam As Ptr) As Integer
  Declare Function SendMessageW Lib "User32" (hWnd As Integer, Msg As Integer, wParam As Integer, lParam As Ptr) As Integer
  
  Dim mb As New MemoryBlock (16)
  GetClientRect (Me.Handle, mb)
  InflateRect (mb, -6, -3)
  
  Const EM_SETRECT = &h00B3
  
  If System.IsFunctionAvailable ("SendMessageW", "User32") Then
    Call SendMessageW (Me.Handle, EM_SETRECT, 0, mb)
  Else
    Call SendMessageA (Me.Handle, EM_SETRECT, 0, mb)
  End If
  
  Me.Refresh
  
#EndIf

-Disable the controls border.

As for the border, since it will requiere to intercept the Paint message and custom draw using the theme framewor of the OS, I just put the TextArea over a canvas that draws a rect whith color Realbasic.FrameColor or Realbasic.HiglightColor