Graphics, Figures & Tablesusing bullets as labels defined by a macro

Information and discussion about graphics, figures & tables in LaTeX documents.
Post Reply
kent
Posts: 57
Joined: Thu Oct 20, 2016 3:41 pm

using bullets as labels defined by a macro

Post by kent »

I often use PGF to draw geometrical figures and I use to label important points using a macro to add bullets at certain points using their coordinates.
All fine, but I should very much be able to invoke my macro with a predefined list say plist by \mgredbullets[\plist], but I can't get it to work.
I have added a short to-the-point attachment with illustrative code.
\mgredbullets[A,B,C,D] works fine with defined points A, B, C and D, also
\mgredbullets[{A,B,C,D}] works fine as seen in the attachement.
Trying to define the list plist by \newcommand{\plist}{{A,B,C,D}} will make \mgredbullets[\plist] fail.
Anybody who can help?

Best regards,
Kent
Attachments
latexforumposting.tex
(1.92 KiB) Downloaded 135 times

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org
LaTeX Beginner's Guide LaTeX Cookbook LaTeX TikZ graphics TikZによるLaTeXグラフィックス
User avatar
Stefan Kottwitz
Site Admin
Posts: 10290
Joined: Mon Mar 10, 2008 9:44 pm

using bullets as labels defined by a macro

Post by Stefan Kottwitz »

Hi Kent,

a quick fix would be expanding the argument before it's applied:

\expandafter\mgbluebullets\expandafter[\plist];

Stefan
LaTeX.org admin
Post Reply