is an option for MoleculePlot and MoleculePlot3D that specifies the style to use for bond labels.
BondLabelStyle
is an option for MoleculePlot and MoleculePlot3D that specifies the style to use for bond labels.
Details
- Any style specification as used in Style can be used as a setting for BondLabelStyle.
- Typical settings include:
-
Automatic use automatic setting style use style for all bonds {b1->style1,b2->style2,…} use stylei for bond bi {pattistylei,…} use stylei for edges matching the pattern patti - Color directives such as Red, as well as text specifications such as Bold or Small, can be given.
- Giving the option setting BondLabelStyle->style is effectively equivalent to replacing the label-like elements of a formatting or related construct by Style[label,style].
Examples
Basic Examples (3)
Set the style for all bond labels:
MoleculePlot[Molecule["butane"], BondLabels -> "Hi", BondLabelStyle -> Directive[Red, Italic, 18]]Specify the style for individual vertex labels:
MoleculePlot[Molecule["butane"], BondLabels -> "Hi", BondLabelStyle -> {Bond[{1, 2}, "Single"] -> Directive[Red, Italic, 18], _ -> Directive[Blue, Bold, 18]}]Specify the style for individual atom labels using a pattern:
MoleculePlot[Molecule["benzaldehyde"], BondLabels -> "BondIndex", BondLabelStyle -> {Bond[{_, "O"}] -> Directive[Blue, Italic, 15], _ -> Directive[Red, Bold, 15]}]Plot the molecule with labels in 3D:
MoleculePlot3D[Molecule["tetraaminomethane"], BondLabels -> "BondIndex", BondLabelStyle -> {Bond[{_, "H"}] -> Directive[Blue, Italic, 15], _ -> Directive[Red, Bold, 15]}]History
Text
Wolfram Research (2021), BondLabelStyle, Wolfram Language function, https://reference.wolfram.com/language/ref/BondLabelStyle.html.
CMS
Wolfram Language. 2021. "BondLabelStyle." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/BondLabelStyle.html.
APA
Wolfram Language. (2021). BondLabelStyle. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/BondLabelStyle.html
BibTeX
@misc{reference.wolfram_2026_bondlabelstyle, author="Wolfram Research", title="{BondLabelStyle}", year="2021", howpublished="\url{https://reference.wolfram.com/language/ref/BondLabelStyle.html}", note=[Accessed: 12-June-2026]}
BibLaTeX
@online{reference.wolfram_2026_bondlabelstyle, organization={Wolfram Research}, title={BondLabelStyle}, year={2021}, url={https://reference.wolfram.com/language/ref/BondLabelStyle.html}, note=[Accessed: 12-June-2026]}