Q:

Indenting bullets

It is not bad enough that I am so new to programming; This week I have done more Google searching and less Google finding than I have ever before.
Delphi v7
I have figured out how to create bullets in my richedit control. What I can't find out is how to indent them when the user creates them.
Any ideas?

A:

Set the TRichEdit.Paragraph.FirstIndent. The bullets will be indented by the additional amount of FirstIndent. (You use FirstIndent because a bullet item is the first line of a new paragraph.)
RichEdit1.Paragraph.FirstIndent := RichEdit1.Paragraph.FirstIndent + 10;

Here's a quick demo based on the RichEdit demo that's shipped with Delphi for years. I simply added two new TToolButtons to the ToolBar (the two right-most buttons, named tbLessIndent and tbMoreIndent respectively, with glyphs from the GlyFx images supplied with Delphi), and added the following event handlers to the existing form as the ToolButton.OnClick events:
procedure TMainForm.tbLessIndentClick(Sender: TObject);
begin
  Editor.Paragraph.FirstIndent := Editor.Paragraph.FirstIndent - 10;
  tbLessIndent.Enabled := Editor.Paragraph.FirstIndent > 9;
end;

procedure TMainForm.tbMoreIndentClick(Sender: TObject);
begin
  Editor.Paragraph.FirstIndent := Editor.Paragraph.FirstIndent + 10;
  tbLessIndent.Enabled := True;
end;

Here's a sample new document with a few items added:

For more info, see the documentation on Numbering and FirstIndent (XE2 docs, but they're about the same)

