1: 新建一个单元文件,复制如下代码,并保存名称为:MultiLinePaletteExpert.pas
unit MultiLinePaletteExpert;
interface
uses
Forms, Controls, ComCtrls;
implementation
type
TMultiLinePalette = class
public
procedure ResizeComponentPalette(Sender : TObject);
end;
var
MultiLinePalette : TMultiLinePalette;
procedure TMultiLinePalette.ResizeComponentPalette(Sender : TObject);
var
AHeight : integer;
begin
with (Sender as TTabControl) do begin
AHeight := Height + DisplayRect.Top - DisplayRect.Bottom + 29;
Constraints.MinHeight := AHeight;
Parent.Constraints.MaxHeight := AHeight;
end;
end; {ResizeMultiLineComponentPalette}
procedure SetMultiLineComponentPalette(MultiLine : boolean);
var
AppBuilder : TForm;
TabControl : TTabControl;
begin
AppBuilder := TForm(Application.FindComponent('AppBuilder'));
if (AppBuilder <> nil) then begin
TabControl := TTabControl(AppBuilder.FindComponent('TabControl'));
if (TabControl <> nil) then begin
TabControl.MultiLine := MultiLine;
if MultiLine then
TabControl.OnResize := MultiLinePalette.ResizeComponentPalette
else
TabControl.OnResize := nil;
end;
end;
end; {SetMultiLineComponentPalette}
initialization
MultiLinePalette := TMultiLinePalette.Create;
SetMultiLineComponentPalette(true);
finalization
SetMultiLineComponentPalette(false);
MultiLinePalette.Free;
end.
2:打开Delphi 7,新建一个Package,Add刚刚保存的MultiLinePaletteExpert.pas文件,编译、安装。想卸载该Package,在Delphi菜单项选择Component/Install Pacgage,找到我们的bpl,remove它就可以了,简单吧!
3:最后打开你的Delphi7 ,Component Palette 是不是变多行了?
分享到:
相关推荐
DELPHI多行显示构件是一种在DELPHI编程环境中用于实现多行文本或信息显示的组件,它扩展了标准的单行文本输入或显示控件的功能。DELPHI,全称为Borland Delphi,是面向对象的Pascal编程语言,以其高效的编译器和强大...
If you do not select automatic installation of the components, or if a version of the TopGrid is already installed on the Delphi Component Palette, the TopGrid components will need to be installed ...
1. **设计阶段**:在Delphi的Form Designer中,从Component Palette面板拖拽一个TToolBar组件到窗体上。然后,可以添加TToolButton组件到TToolBar中,每个ToolButton代表工具栏上的一个按钮。 2. **运行时控制**:...
Raize控件 delphi版本 ... Restart RAD Studio and you will see the following pages on the component palette: Raize Panels Raize Edits Raize Lists Raize Buttons Raize Display Raize Shell Raize Widgets
在设计界面上,从Component Palette中选择Data Controls > ADO Components > TADOConnection,并将其拖放到Form上。然后,双击该组件打开其属性对话框,配置连接字符串。连接字符串应包含数据库类型、服务器地址、...
这通常通过打开Component Palette,然后在Components分类下找到Rave Reports组件,将其拖放到Form上。接着,你需要在报表设计视图中创建一个新的页面,用于显示条形码。 Rave报表支持多种数据源,可以是数据库、...
将BPL及其依赖的DLL文件放入系统目录或Delphi的BPL目录,然后在Delphi的Component Palette中手动添加新页,选择对应的BPL文件,即可使用组件。 4. **JAR或ZIP文件**:某些开源组件可能以源码的形式提供,例如Java ...
3. 安装完成后,打开Delphi IDE,你会在组件面板(Component Palette)上看到新增的TMS组件组,表明安装成功。 TMS Component Pack的核心价值在于其丰富的组件集合。其中包括但不限于: - **UI控件**:如高度定制...
教程通常会指导用户如何将组件库导入到Delphi的Component Palette,设置编译路径,以及如何解决可能出现的依赖问题。此外,教程还可能涵盖如何在项目中使用新添加的组件,以及配置其属性和方法。 **总结** Raize4 ...
在Delphi集成开发环境中,打开你的项目,从Component Palette(组件面板)的ActiveX类别中找到TVideoCapture组件,将其拖放到Form上。这个组件会自动在设计界面上显示一个预览窗口。 2. 配置TVideoCapture组件: ...
这可以通过从Component Palette选择并放置元件到Form上来实现,然后通过调整元件的位置和大小,或使用Object Inspector来设置元件属性。其次,编写代码阶段涉及到为这些用户界面元素指定事件处理程序,并在Code ...
Unfortunately, when you restart the IDE, the component palette pages for the newly installed components will appear at the end of the component palette. If you would like to move the Raize pages to ...
在Delphi中,你可以通过“Component Palette”添加Indy到你的工程,然后在你的Form上放置一个TIdFTP组件。 2. **配置TIdFTP组件**:在TIdFTP组件上设置服务器地址(Host)、用户名(Username)和密码(Password)。...
步骤1:在Delphi的Form Designer中,从Component Palette(组件面板)中拖一个TTreeView到窗体上,调整其大小和位置以适应左侧区域。 步骤2:为TTreeView添加数据。这通常涉及到为每个菜单项创建一个TTreeNode,并...
1. **设置TSerialPort组件**:在Delphi的Form设计界面中,从Component Palette面板拖拽一个TSerialPort组件到Form上。接着,我们需要配置该组件的属性,如ComPort(选择要连接的COM口)、BaudRate(波特率,如9600、...
Unfortunately, when you restart the IDE, the component palette pages for the newly installed components will appear at the end of the component palette. If you would like to move the Raize pages to ...
WELCOME TO RAIZE ... Restart RAD Studio and you will see the following pages on the component palette: Raize Panels Raize Edits Raize Lists Raize Buttons Raize Display Raize Shell Raize Widgets
在Component Palette中找到Data Access Components,然后将TADOConnection拖放到Form上。接着,我们需要配置这个组件,设置其ConnectionString属性。对于Windows身份验证,Connection String通常包含以下部分: ```...
the IDE, the component palette pages for Raize Components will appear at the end of the component palette. If you would like to move the Raize pages to the front of the palette, there is an a ...
1. **启动Delphi并新建组件**:选择菜单的"Component"/"New Component"选项。在弹出的对话框中,选择Ancestor Type为TButton,这意味着你的新组件将基于TButton组件进行扩展。 2. **设置组件信息**:在对话框中,...