How to make a new (complex) component visible at design time? lazarus / 5-Lazarus Extra Components ---------------------------------------------------------------------- dgaspary · 2009-10-30 20:09 Scenario: 1-I have created a New component, extending TPanel, let's name it TMyPanel. 2-When I click on the form, the component is visible as expected. But how can I create more complex components ? Example: 1-TMyPanel now will have A TMemo Aligned onclient Area and a TEdit aligned on Top. 2-Now when I click at my form to add the TMyPanel, Just the base TPanel component is displayed. How to make The inner components to show also ? Resources ? Thanks. ---------------------------------------------------------------------- Zaher · 2009-10-31 12:57 Be sure you Made FMemo.Parent := Self; //self = TMyPanel FMemo.Visible := True; FMemo.SetSize(...) ---------------------------------------------------------------------- dgaspary · 2009-10-31 16:05 Quote from: Zaher on October 31, 2009, 01:57:51 pmBe sure you Made FMemo.Parent := Self; //self = TMyPanel FMemo.Visible := True; FMemo.SetSize(...) The ".parent:=self" was a nice tip. I think "TMemo.Create(self)" was enough to create a relationship between the components. Thank you! ---------------------------------------------------------------------- dgaspary · 2009-10-31 16:19 Another question... How to make the container panel and the inner components behave as one whole component ? My component has a top panel (align = alTop)  and a TMemo (align = alClient). Example: When I click to drag the component(TMyPanel) at design time, instead of dragging it, the inner component under mouse pointer is selected. I wanna click at any part of the component and drag it, don't get selected an inner component. ---------------------------------------------------------------------- Zaher · 2009-11-01 13:43 try FMemo.ControlStyle := ControlStyle + [csNoDesignSelectable]; ---------------------------------------------------------------------- dgaspary · 2009-11-01 19:18 Quote from: Zaher on November 01, 2009, 02:43:03 pmtry FMemo.ControlStyle := ControlStyle + [csNoDesignSelectable]; Now it works as I was expecting. Thank you, Zaher!