MCPcopy Create free account
hub / github.com/cpmech/plotpy / options_works

Function options_works

src/text.rs:295–311  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

293
294 #[test]
295 fn options_works() {
296 let mut text = Text::new();
297 text.set_color("red")
298 .set_align_horizontal("center")
299 .set_align_vertical("center")
300 .set_fontsize(8.0)
301 .set_rotation(45.0);
302 let opt = text.options();
303 assert_eq!(
304 opt,
305 ",color='red'\
306 ,ha='center'\
307 ,va='center'\
308 ,fontsize=8\
309 ,rotation=45"
310 );
311 }
312
313 #[test]
314 fn options_box_works() {

Callers

nothing calls this directly

Calls 6

set_rotationMethod · 0.80
set_fontsizeMethod · 0.45
set_align_verticalMethod · 0.45
set_align_horizontalMethod · 0.45
set_colorMethod · 0.45
optionsMethod · 0.45

Tested by

no test coverage detected