diff --git a/CHANGELOG.md b/CHANGELOG.md index 4f02053f..b55e14b3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -22,6 +22,9 @@ NOTE: [`eframe`](eframe/CHANGELOG.md), [`egui_web`](egui_web/CHANGELOG.md) and [ * Fix [defocus-bug on touch screens](https://github.com/emilk/egui/issues/288). * Fix bug with the layout of wide `DragValue`:s. +### Removed 🔥 +* Moved experimental markup language to `egui_demo_lib` + ## 0.11.0 - 2021-04-05 - Optimization, screen reader & new layout logic diff --git a/egui/src/experimental/mod.rs b/egui/src/experimental/mod.rs deleted file mode 100644 index 5a6084cf..00000000 --- a/egui/src/experimental/mod.rs +++ /dev/null @@ -1,8 +0,0 @@ -//! Experimental parts of egui, that may change suddenly or get removed. -//! -//! Be very careful about depending on the experimental parts of egui! - -pub mod easy_mark_parser; -mod easy_mark_viewer; - -pub use easy_mark_viewer::easy_mark; diff --git a/egui/src/lib.rs b/egui/src/lib.rs index dd64be66..a5a27603 100644 --- a/egui/src/lib.rs +++ b/egui/src/lib.rs @@ -296,7 +296,6 @@ pub mod any; pub mod containers; mod context; mod data; -pub mod experimental; mod frame_state; pub(crate) mod grid; mod id; diff --git a/egui_demo_lib/src/apps/mod.rs b/egui_demo_lib/src/apps/mod.rs index 0693c74c..f801529f 100644 --- a/egui_demo_lib/src/apps/mod.rs +++ b/egui_demo_lib/src/apps/mod.rs @@ -1,13 +1,11 @@ mod color_test; mod demo; -mod easy_mark_editor; mod fractal_clock; #[cfg(feature = "http")] mod http_app; pub use color_test::ColorTest; pub use demo::DemoApp; -pub use easy_mark_editor::EasyMarkEditor; pub use fractal_clock::FractalClock; #[cfg(feature = "http")] pub use http_app::HttpApp; diff --git a/egui_demo_lib/src/apps/easy_mark_editor.rs b/egui_demo_lib/src/easy_mark/easy_mark_editor.rs similarity index 98% rename from egui_demo_lib/src/apps/easy_mark_editor.rs rename to egui_demo_lib/src/easy_mark/easy_mark_editor.rs index e6fccb3f..3b6105f0 100644 --- a/egui_demo_lib/src/apps/easy_mark_editor.rs +++ b/egui_demo_lib/src/easy_mark/easy_mark_editor.rs @@ -44,7 +44,7 @@ impl EasyMarkEditor { ScrollArea::auto_sized() .id_source("rendered") .show(&mut columns[1], |ui| { - egui::experimental::easy_mark(ui, &self.code); + crate::easy_mark::easy_mark(ui, &self.code); }); }); } diff --git a/egui/src/experimental/easy_mark_parser.rs b/egui_demo_lib/src/easy_mark/easy_mark_parser.rs similarity index 99% rename from egui/src/experimental/easy_mark_parser.rs rename to egui_demo_lib/src/easy_mark/easy_mark_parser.rs index 13487e76..29b17a20 100644 --- a/egui/src/experimental/easy_mark_parser.rs +++ b/egui_demo_lib/src/easy_mark/easy_mark_parser.rs @@ -61,7 +61,7 @@ pub struct Style { /// /// # Example: /// ``` -/// # use egui::experimental::easy_mark_parser::Parser; +/// # use egui_demo_lib::easy_mark::parser::Parser; /// for item in Parser::new("Hello *world*!") { /// } /// diff --git a/egui/src/experimental/easy_mark_viewer.rs b/egui_demo_lib/src/easy_mark/easy_mark_viewer.rs similarity index 99% rename from egui/src/experimental/easy_mark_viewer.rs rename to egui_demo_lib/src/easy_mark/easy_mark_viewer.rs index 58e6aaf2..0970dda8 100644 --- a/egui/src/experimental/easy_mark_viewer.rs +++ b/egui_demo_lib/src/easy_mark/easy_mark_viewer.rs @@ -1,5 +1,5 @@ use super::easy_mark_parser as easy_mark; -use crate::*; +use egui::*; /// Parse and display a VERY simple and small subset of Markdown. pub fn easy_mark(ui: &mut Ui, easy_mark: &str) { diff --git a/egui_demo_lib/src/easy_mark/mod.rs b/egui_demo_lib/src/easy_mark/mod.rs new file mode 100644 index 00000000..8c56bd8d --- /dev/null +++ b/egui_demo_lib/src/easy_mark/mod.rs @@ -0,0 +1,9 @@ +//! Experimental markup language + +mod easy_mark_editor; +pub mod easy_mark_parser; +mod easy_mark_viewer; + +pub use easy_mark_editor::EasyMarkEditor; +pub use easy_mark_parser as parser; +pub use easy_mark_viewer::easy_mark; diff --git a/egui_demo_lib/src/lib.rs b/egui_demo_lib/src/lib.rs index d0a0c0b4..67f5c675 100644 --- a/egui_demo_lib/src/lib.rs +++ b/egui_demo_lib/src/lib.rs @@ -58,6 +58,7 @@ #![allow(clippy::manual_range_contains)] mod apps; +pub mod easy_mark; pub(crate) mod frame_history; mod wrap_app; diff --git a/egui_demo_lib/src/wrap_app.rs b/egui_demo_lib/src/wrap_app.rs index 93b28bdd..3461a588 100644 --- a/egui_demo_lib/src/wrap_app.rs +++ b/egui_demo_lib/src/wrap_app.rs @@ -4,7 +4,7 @@ #[cfg_attr(feature = "persistence", serde(default))] pub struct Apps { demo: crate::apps::DemoApp, - easy_mark_editor: crate::apps::EasyMarkEditor, + easy_mark_editor: crate::easy_mark::EasyMarkEditor, #[cfg(feature = "http")] http: crate::apps::HttpApp, clock: crate::apps::FractalClock,