Questions tagged [tframe]

TFrame is a VCL visual control acting as a container for components. It can be nested within forms or other frames. It is defined in Forms.pas unit.

72 questions
6
votes
3 answers

Is there a way to have a KeyPreview-like functionality when working with Frames?

I would like to have a KeyPreview functionality within Frames, I mean, that when the input (say, one of the controls of the frame is selected, or the mouse is inside) is in a frame (which would have several panels and other controls) then the keys…
Rodrigo Gómez
  • 1,079
  • 8
  • 24
5
votes
3 answers

create Tframes on runtime:

is it posible to create runtime frame and add existing panels like setting the parent of panel to the frame? and when it added, dulplicate the frame and use it? like: f:= Tframe. create(..) ... panel3.parent = f; //where panel3 has many…
XBasic3000
  • 3,418
  • 5
  • 46
  • 91
5
votes
3 answers

Is it possible to visually design a custom component at design time?

I am venturing into making my own components in Delphi. I'm having difficulty getting started with component development. I want to make a composite control ie a control made up of several other controls, eg like an address form or something like…
csharpdefector
  • 813
  • 8
  • 19
4
votes
5 answers

Registering a custom Frame

In Delphi 2009, In one of my projects, I have a custom frame with some controls on it which I want to use as the base class for some other controls. I want to register this frame as an IDE wizard to be available in New Items list. When I add my…
vcldeveloper
  • 7,399
  • 2
  • 33
  • 39
4
votes
2 answers

TFrame inheritance refactoring

Yet another TFrame IDE-registered-component question from me. Thanks for all the help, fellow programmers. : ) Playing around with Darrian's TFrame inheritance suggestion here: Specifics: Basically, I have a TFrame-based component that I've…
Jamo
  • 3,238
  • 6
  • 40
  • 66
4
votes
1 answer

Delphi - How to close a form from WITHIN a TFrame on that form?

In Delphi 2010, I am creating a form, and then creating a TFrame, assigning TFrame.Parent to the form, and then showing the form MODALLY. Works fine... The frame has a DBNavigator, a field DBFields,etc. When the user clicks on Post/Save, I want…
user1009073
  • 3,160
  • 7
  • 40
  • 82
4
votes
2 answers

EventHandler inside a TFrame?

I have a TForm (TVehicleEditForm) with 3 identical TFrames (TVehicleUnitFrame) inside. The idea was that every instance of the frame handle own events by a eventhandler inside the frame. The problem is that the eventhandler is not called. I have…
Roland Bengtsson
  • 5,058
  • 9
  • 58
  • 99
3
votes
5 answers

Passing parameters to a delphi TFrame

To avoid singletons and global variables I'd like to be able to pass parameters to a TFrame component. However since a TFrame normally is included on form at design time it is only possible to use the default constructor. The parent form can of…
ajob
  • 227
  • 1
  • 4
  • 9
3
votes
1 answer

delphi: how to to store TCustomFrames and records in one list

I am using a TObjectList to store TCustomFrames. Now i want to store some more information regarding to the TCustomFrame in the same list. A record would be nice. Which delphi class would you prefer to store TCustomFrames and records…
Dennis F.
  • 428
  • 4
  • 15
3
votes
3 answers

How to access TFrame's canvas?

Using: Delphi XE2, VCL 32-bit application, Windows 8 I'm trying to paint the background of my frame onto a panel (I'm using TJvPanel, because it exposes the OnPaint event) which is a child control of the frame. After reading this post and adding a…
Steve F
  • 1,527
  • 1
  • 29
  • 55
2
votes
1 answer

Deleting TFrame from form at run time

I am using C++ Builder to create a VCL form application. Right now I have a TFrame containing a bunch of components and it looks like this... I also have a button call "Add". Basically every time I press that Add button on the form, a new TFrame is…
livelaughlove
  • 376
  • 3
  • 9
  • 21
2
votes
1 answer

Why don't forms receive WM_NOTIFY messages for children of a TFrame?

The WM_NOTIFY message is often used for in-place "tool tips" (message balloon) and other control notifications, but if I place a control on a TFrame, then WM_NOTIFY messages never occur for those controls. Why aren't those messages sent to my form…
Alfa000
  • 29
  • 2
2
votes
1 answer

TFrame overriding style color

I have a frame, with color clSkyBlue, which sits in an application with panels and various things with the color clSkyBlue. The program uses TStyleManager this sets the color to the current style. (ie windows10,windows10 dark etc). The problem is…
iplayfast
  • 140
  • 10
2
votes
2 answers

Delphi: refer to control from thread in frame

There is a FRAME (not a form) and a thread. How to refer to Frame's control from the thread? For example I want to disable a button from a thread. But I don't have a pointer to the button, no global variables in the frame. Thanks!
maxfax
  • 4,281
  • 12
  • 74
  • 120
2
votes
1 answer

How to save & load TFrame contents?

I use the following code to save & load my Form: public constructor Create(AOwner: TComponent); override; procedure BeforeDestruction; override; var PreservePath: String; constructor TMyForm.Create(AOwner: TComponent); begin …
Issam
  • 65
  • 5