* * *

Author Topic: TToolBar with TEdit?  (Read 308 times)

tudi_x

  • Hero Member
  • *****
  • Posts: 524
TToolBar with TEdit?
« on: October 02, 2018, 12:18:24 pm »
hi,
i see on the web side the user experience is providing a search field in the navigation bar (ex. Github, StackOverflow).
and in Lazarus we have TToolBar to easily concentrate user actions, object that has many years of good serving.

is there a way to easily draft something like a navigation bar in some other way than placing the objects one by one?
what do you guys think of an object that could create a similar user experience like the so called navigation bar in StackOverflow site? something like a TToolBar accepting also TEdit.
this could be useful also for mobile apps..
Lazarus 1.8.4 64b on MX Linux "Horizon"

Blaazen

  • Hero Member
  • *****
  • Posts: 2639
  • POKE 54296,15
    • Eye-Candy Controls
Re: TToolBar with TEdit?
« Reply #1 on: October 02, 2018, 01:21:34 pm »
You can use TCoolBar: one band for TEdit, the other for TToolBar. There's also TControlBar, it allows the same.
Lazarus 2.1.0 r59317M FPC 3.3.1 r39660 x86_64-linux-qt Chakra, Qt 4.8.7/5.11.1, Plasma 5.13.5
Lazarus 1.8.2 r57369 FPC 3.0.4 i386-win32-win32/win64 Wine 3.14

Try Eye-Candy Controls: https://sourceforge.net/projects/eccontrols/files/

wp

  • Hero Member
  • *****
  • Posts: 4982
Re: TToolBar with TEdit?
« Reply #2 on: October 02, 2018, 01:43:18 pm »
A toolbar does accept any (or at least: most) controls, but has its own ideas about positioning. The attached screenshot shows a toolbar with added TEdit, TDBNavigator, TCombobox and TCheckbox. The BorderSpacing.Left of the TCheckbox (10) is ignored.

It may be better to add a panel to the toolbar and put the controls into the panel.
Lazarus trunk / fpc 3.0.4 / all 32-bit on Win-10

tudi_x

  • Hero Member
  • *****
  • Posts: 524
Re: TToolBar with TEdit?
« Reply #3 on: October 02, 2018, 02:47:32 pm »
thank you!
i will go with the panel approach for now.
Lazarus 1.8.4 64b on MX Linux "Horizon"

 

Recent

Get Lazarus at SourceForge.net. Fast, secure and Free Open Source software downloads Open Hub project report for Lazarus