快速报告-项目符号文本 [英] Fast reports - bulleted text
问题描述
有没有办法在快速报告4.13中将tekst标记为项目符号?我有一个备注字段,我想将其显示为项目符号.如果不在快速报告中,是否还有其他Delphi组件可以做到这一点?
Is there a way you can have bulleted tekst in fast reports 4.13 ? I have a memo field which I would like to display bulleted. If not in fast reports are there any other delphi components that can do that ?
推荐答案
RichText
对象( TfrxRichView
)支持项目符号文本.
The RichText
object (TfrxRichView
) supports bulleted text.
自然会提出的问题是如何从代码中创建项目符号列表.好吧,这很容易.您只需将 TfrxRichView
对象的内部 RichEdit
的当前 Paragraph
的 Numbering
属性设置为nsBullet
.假设您在报表 frxReport1
上放置了一个名为 Rich1
的 RichText
对象,则可以使用如下代码制作三个项目符号项:>
The question which may naturally raise up, is how to make that bulleted list from code. Well, that's quite easy. You just set the Numbering
property of the current Paragraph
for the inner RichEdit
of the TfrxRichView
object to nsBullet
. Assuming you have a RichText
object named Rich1
placed on a report frxReport1
, you can use a code like this to make three bulleted items:
uses
frxClass, frxRich, frxRichEdit;
procedure TForm2.Button1Click(Sender: TObject);
var
Component: TfrxComponent;
begin
Component := frxReport1.FindObject('Rich1');
if Component is TfrxRichView then
begin
TfrxRichView(Component).RichEdit.Clear;
TfrxRichView(Component).RichEdit.Paragraph.Numbering := nsBullet;
TfrxRichView(Component).RichEdit.Lines.Add('Item 1');
TfrxRichView(Component).RichEdit.Lines.Add('Item 2');
TfrxRichView(Component).RichEdit.Lines.Add('Item 3');
frxReport1.ShowReport;
end;
end;
这篇关于快速报告-项目符号文本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!