summaryrefslogtreecommitdiffstats
path: root/graphics/src/widget/canvas.rs
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón <hector0193@gmail.com>2020-11-26 02:52:34 +0100
committerLibravatar GitHub <noreply@github.com>2020-11-26 02:52:34 +0100
commit1f7e8b7f3d1804c39c8e0934b25f3ef178de269c (patch)
tree380d9224b81537e460ea7f9fe84c0c912d3f4cbf /graphics/src/widget/canvas.rs
parentbffaeed9fd44619491c012cd9270043828c1849c (diff)
parent01322f69a406eee76014f5e2834336e2295ad80e (diff)
downloadiced-1f7e8b7f3d1804c39c8e0934b25f3ef178de269c.tar.gz
iced-1f7e8b7f3d1804c39c8e0934b25f3ef178de269c.tar.bz2
iced-1f7e8b7f3d1804c39c8e0934b25f3ef178de269c.zip
Merge pull request #632 from hecrj/improvement/update-docs
Use intra-doc links
Diffstat (limited to 'graphics/src/widget/canvas.rs')
-rw-r--r--graphics/src/widget/canvas.rs11
1 files changed, 0 insertions, 11 deletions
diff --git a/graphics/src/widget/canvas.rs b/graphics/src/widget/canvas.rs
index ae0d87a4..95ede50f 100644
--- a/graphics/src/widget/canvas.rs
+++ b/graphics/src/widget/canvas.rs
@@ -3,9 +3,6 @@
//! A [`Canvas`] widget can be used to draw different kinds of 2D shapes in a
//! [`Frame`]. It can be used for animation, data visualization, game graphics,
//! and more!
-//!
-//! [`Canvas`]: struct.Canvas.html
-//! [`Frame`]: struct.Frame.html
use crate::{Backend, Defaults, Primitive, Renderer};
use iced_native::layout;
use iced_native::mouse;
@@ -41,8 +38,6 @@ pub use text::Text;
/// A widget capable of drawing 2D graphics.
///
-/// [`Canvas`]: struct.Canvas.html
-///
/// # Examples
/// The repository has a couple of [examples] showcasing how to use a
/// [`Canvas`]:
@@ -108,8 +103,6 @@ impl<Message, P: Program<Message>> Canvas<Message, P> {
const DEFAULT_SIZE: u16 = 100;
/// Creates a new [`Canvas`].
- ///
- /// [`Canvas`]: struct.Canvas.html
pub fn new(program: P) -> Self {
Canvas {
width: Length::Units(Self::DEFAULT_SIZE),
@@ -120,16 +113,12 @@ impl<Message, P: Program<Message>> Canvas<Message, P> {
}
/// Sets the width of the [`Canvas`].
- ///
- /// [`Canvas`]: struct.Canvas.html
pub fn width(mut self, width: Length) -> Self {
self.width = width;
self
}
/// Sets the height of the [`Canvas`].
- ///
- /// [`Canvas`]: struct.Canvas.html
pub fn height(mut self, height: Length) -> Self {
self.height = height;
self