MCPcopy Create free account
hub / github.com/donkeyteethUX/iced_plot / shape_uses_axes_transform

Method shape_uses_axes_transform

src/plot_widget.rs:1172–1187  ·  view source on GitHub ↗
(&self, id: ShapeId)

Source from the content-addressed store, hash-verified

1170 .align_x(Horizontal::Left)
1171 .align_y(Vertical::Bottom)
1172 .style(container::transparent);
1173 tick_elements.push(positioned_label.into());
1174 }
1175 }
1176
1177 if let Some(formatter) = &self.y_axis_formatter {
1178 for tick in &self.y_ticks {
1179 let label_text = formatter(tick.tick);
1180 let text_widget = tick_text(label_text);
1181 let positioned_label = widget::container(text_widget)
1182 .width(Length::Fill)
1183 .height(Length::Fill)
1184 .padding(padding::top(tick.screen_pos - 5.0))
1185 .align_x(alignment::Horizontal::Left)
1186 .align_y(Vertical::Top)
1187 .style(container::transparent);
1188 tick_elements.push(positioned_label.into());
1189 }
1190 }

Calls 3

mapMethod · 0.80
getMethod · 0.80
uses_axes_coordinatesMethod · 0.80

Tested by

no test coverage detected