Recent

Author Topic: [Solved] ATTabs_Package and adding components  (Read 3108 times)

madref

  • Hero Member
  • *****
  • Posts: 949
  • ..... A day not Laughed is a day wasted !!
    • Nursing With Humour
[Solved] ATTabs_Package and adding components
« on: January 09, 2018, 12:36:03 pm »
I am using ATTabs_Packagde 1.6 and i have created one ATTabs.
I have it setup in the colors i want, but i can't add components to the tabs.


How can i add components to the different tabs?
« Last Edit: January 09, 2018, 09:35:13 pm by madref »
You treat a disease, you win, you lose.
You treat a person and I guarantee you, you win, no matter the outcome.

Lazarus 3.99 (rev main_3_99-649-ge13451a5ab) FPC 3.3.1 x86_64-darwin-cocoa
Mac OS X Monterey

taazz

  • Hero Member
  • *****
  • Posts: 5368
Re: ATTabs_Package and adding components
« Reply #1 on: January 09, 2018, 01:00:57 pm »
you can't. Tabs are not pages. It only paints the tabs and has events you can use to respond to various actions (change tab etc).
Good judgement is the result of experience … Experience is the result of bad judgement.

OS : Windows 7 64 bit
Laz: Lazarus 1.4.4 FPC 2.6.4 i386-win32-win32/win64

madref

  • Hero Member
  • *****
  • Posts: 949
  • ..... A day not Laughed is a day wasted !!
    • Nursing With Humour
Re: ATTabs_Package and adding components
« Reply #2 on: January 09, 2018, 01:14:32 pm »
This sucks....
Is there a component that does it and looks like ATTabs?
You treat a disease, you win, you lose.
You treat a person and I guarantee you, you win, no matter the outcome.

Lazarus 3.99 (rev main_3_99-649-ge13451a5ab) FPC 3.3.1 x86_64-darwin-cocoa
Mac OS X Monterey

taazz

  • Hero Member
  • *****
  • Posts: 5368
Re: ATTabs_Package and adding components
« Reply #3 on: January 09, 2018, 01:26:02 pm »
This sucks....
Is there a component that does it and looks like ATTabs?
I don't know of any control that behaves as tpagecontrol with custom look.
Good judgement is the result of experience … Experience is the result of bad judgement.

OS : Windows 7 64 bit
Laz: Lazarus 1.4.4 FPC 2.6.4 i386-win32-win32/win64

madref

  • Hero Member
  • *****
  • Posts: 949
  • ..... A day not Laughed is a day wasted !!
    • Nursing With Humour
Re: ATTabs_Package and adding components
« Reply #4 on: January 09, 2018, 01:43:10 pm »
Then i will add a page control component and make it look like the tabs are being used :D
You treat a disease, you win, you lose.
You treat a person and I guarantee you, you win, no matter the outcome.

Lazarus 3.99 (rev main_3_99-649-ge13451a5ab) FPC 3.3.1 x86_64-darwin-cocoa
Mac OS X Monterey

Handoko

  • Hero Member
  • *****
  • Posts: 5153
  • My goal: build my own game engine using Lazarus
Re: ATTabs_Package and adding components
« Reply #5 on: January 09, 2018, 01:54:51 pm »
I am using ATTabs_Packagde 1.6 and i have created one ATTabs.
I have it setup in the colors i want, but i can't add components to the tabs.

Maybe you can combine ATTabs and TNotebook. TNotebook allows you to have multiple pages. When user click a tab (on ATTabs), use TNotebook.PageIndex to switch page.

madref

  • Hero Member
  • *****
  • Posts: 949
  • ..... A day not Laughed is a day wasted !!
    • Nursing With Humour
Re: ATTabs_Package and adding components
« Reply #6 on: January 09, 2018, 02:18:39 pm »
i am doing the came with TPageControl.
Code: Pascal  [Select][+][-]
  1. procedure TForm_Evaluatie_Referee.ATTabs_EvaluatieTabClick(Sender: TObject);
  2. begin
  3.   PageControl1.TabIndex := (Sender as TATTabs).TabIndex;
  4. end;
« Last Edit: January 09, 2018, 02:20:11 pm by madref »
You treat a disease, you win, you lose.
You treat a person and I guarantee you, you win, no matter the outcome.

Lazarus 3.99 (rev main_3_99-649-ge13451a5ab) FPC 3.3.1 x86_64-darwin-cocoa
Mac OS X Monterey

Blaazen

  • Hero Member
  • *****
  • Posts: 3237
  • POKE 54296,15
    • Eye-Candy Controls
Re: ATTabs_Package and adding components
« Reply #7 on: January 09, 2018, 03:00:15 pm »
Yes, TPageControl with property ShowTab set to False. And you can switch tabs with any component: ATTabs, TTreeView and others. I use it to.
Lazarus 2.3.0 (rev main-2_3-2863...) FPC 3.3.1 x86_64-linux-qt Chakra, Qt 4.8.7/5.13.2, Plasma 5.17.3
Lazarus 1.8.2 r57369 FPC 3.0.4 i386-win32-win32/win64 Wine 3.21

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

taazz

  • Hero Member
  • *****
  • Posts: 5368
Re: ATTabs_Package and adding components
« Reply #8 on: January 09, 2018, 03:12:15 pm »
i am doing the came with TPageControl.
Code: Pascal  [Select][+][-]
  1. procedure TForm_Evaluatie_Referee.ATTabs_EvaluatieTabClick(Sender: TObject);
  2. begin
  3.   PageControl1.TabIndex := (Sender as TATTabs).TabIndex;
  4. end;
what happens if you move the tab with your mouse at runtime in to a new position?
Good judgement is the result of experience … Experience is the result of bad judgement.

OS : Windows 7 64 bit
Laz: Lazarus 1.4.4 FPC 2.6.4 i386-win32-win32/win64

Blaazen

  • Hero Member
  • *****
  • Posts: 3237
  • POKE 54296,15
    • Eye-Candy Controls
Re: ATTabs_Package and adding components
« Reply #9 on: January 09, 2018, 03:20:42 pm »
Hmmm, he must restrict moving of tabs or use some Tag property (if ATTab has it).
Lazarus 2.3.0 (rev main-2_3-2863...) FPC 3.3.1 x86_64-linux-qt Chakra, Qt 4.8.7/5.13.2, Plasma 5.17.3
Lazarus 1.8.2 r57369 FPC 3.0.4 i386-win32-win32/win64 Wine 3.21

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

taazz

  • Hero Member
  • *****
  • Posts: 5368
Re: ATTabs_Package and adding components
« Reply #10 on: January 09, 2018, 03:21:55 pm »
Hmmm, he must restrict moving of tabs or use some Tag property (if ATTab has it).
or assign the tpage to the tab's data property and set the activepage property instead of activepageindex.
« Last Edit: January 09, 2018, 03:58:30 pm by taazz »
Good judgement is the result of experience … Experience is the result of bad judgement.

OS : Windows 7 64 bit
Laz: Lazarus 1.4.4 FPC 2.6.4 i386-win32-win32/win64

madref

  • Hero Member
  • *****
  • Posts: 949
  • ..... A day not Laughed is a day wasted !!
    • Nursing With Humour
Re: ATTabs_Package and adding components
« Reply #11 on: January 09, 2018, 09:35:57 pm »
i am doing the came with TPageControl.
Code: Pascal  [Select][+][-]
  1. procedure TForm_Evaluatie_Referee.ATTabs_EvaluatieTabClick(Sender: TObject);
  2. begin
  3.   PageControl1.TabIndex := (Sender as TATTabs).TabIndex;
  4. end;
what happens if you move the tab with your mouse at runtime in to a new position?


I have disabled this feature and also disabled adding a new one
You treat a disease, you win, you lose.
You treat a person and I guarantee you, you win, no matter the outcome.

Lazarus 3.99 (rev main_3_99-649-ge13451a5ab) FPC 3.3.1 x86_64-darwin-cocoa
Mac OS X Monterey

 

TinyPortal © 2005-2018