Skip to content

Commit 1b77520

Browse files
committed
change names for member crates
1 parent 63b8ce9 commit 1b77520

File tree

8 files changed

+19
-76
lines changed

8 files changed

+19
-76
lines changed

Cargo.toml

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ version = "0.1.0"
44
edition = "2021"
55

66
[dependencies]
7-
parser = { version = "*", path = "parser" }
8-
macros = { version = "*", path = "macros" }
7+
egui_xml_parser = { version = "*", path = "parser" }
8+
egui_xml_macros = { version = "*", path = "macros" }
99
egui_extras = "0.27"
1010

1111
[dev-dependencies]

examples/file.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
use eframe::egui;
2-
use macros::load_layout_file;
2+
use egui_xml::load_layout_file;
33

44
fn main() -> Result<(), eframe::Error> {
55
let options = eframe::NativeOptions {

macros/Cargo.toml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[package]
2-
name = "macros"
2+
name = "egui_xml_macros"
33
version = "0.1.0"
44
edition = "2021"
55

@@ -11,6 +11,6 @@ syn = "2.0"
1111
quote = "1.0"
1212
quote_into = "0.2.0"
1313
proc-macro2 = "1.0"
14-
parser = { path = "../parser" }
14+
egui_xml_parser = { path = "../parser" }
1515
strum_macros = "0.26"
1616
strum = "0.26"

macros/src/layout/strip.rs

+4-2
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use std::{
55
str::{from_utf8, FromStr},
66
};
77

8-
use parser::{
8+
use egui_xml_parser::{
99
attribute::{parse_optional_hybrid_attribute, AttributeBool, AttributeF32, HybridAttribute},
1010
Node,
1111
};
@@ -18,7 +18,9 @@ use strum_macros::EnumString;
1818

1919
use crate::XMLContext;
2020

21-
use parser::attribute::{parse_hybrid_attribute, parse_optional_rust_attribute, parse_string};
21+
use egui_xml_parser::attribute::{
22+
parse_hybrid_attribute, parse_optional_rust_attribute, parse_string,
23+
};
2224

2325
#[derive(PartialEq, Eq, EnumString)]
2426
enum DirectionBlueprint {

macros/src/lib.rs

+7-7
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@ extern crate proc_macro;
2929

3030
use std::{cell::RefCell, rc::Rc};
3131

32+
use egui_xml_parser::{Node, XMLForm};
3233
use layout::strip::expand_strip;
33-
use parser::{Node, XMLForm};
3434
use proc_macro::TokenStream;
3535

3636
use quote::{quote, TokenStreamExt};
@@ -59,12 +59,12 @@ fn expand_node(
5959
ctx: &XMLContext,
6060
) -> Result<proc_macro2::TokenStream, String> {
6161
match &*node.borrow() {
62-
parser::Node::Panel { children, .. } => expand_nodes(children, ctx),
63-
parser::Node::Rust { code, .. } => Ok(code.parse().unwrap()),
64-
parser::Node::Border { .. } => Ok(quote! {}),
65-
parser::Node::Grid { .. } => Ok(quote! {}),
66-
parser::Node::Default { children, .. } => expand_nodes(children, ctx),
67-
parser::Node::Strip { .. } => expand_strip(node, ctx),
62+
egui_xml_parser::Node::Panel { children, .. } => expand_nodes(children, ctx),
63+
egui_xml_parser::Node::Rust { code, .. } => Ok(code.parse().unwrap()),
64+
egui_xml_parser::Node::Border { .. } => Ok(quote! {}),
65+
egui_xml_parser::Node::Grid { .. } => Ok(quote! {}),
66+
egui_xml_parser::Node::Default { children, .. } => expand_nodes(children, ctx),
67+
egui_xml_parser::Node::Strip { .. } => expand_strip(node, ctx),
6868
}
6969
}
7070

parser/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[package]
2-
name = "parser"
2+
name = "egui_xml_parser"
33
version = "0.1.0"
44
edition = "2021"
55

parser/test1.fmt

-59
This file was deleted.

src/lib.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
pub use macros::load_layout;
2-
pub use macros::load_layout_file;
1+
pub use egui_xml_macros::load_layout;
2+
pub use egui_xml_macros::load_layout_file;

0 commit comments

Comments
 (0)