mirror of
https://github.com/GraphiteEditor/Graphite.git
synced 2026-09-29 06:28:12 +08:00
Improve previewing node data (#1446)
* Improve preview * Improve contrast * Restructure in order to duplicate code * Code review nits --------- Co-authored-by: Keavon Chambers <keavon@keavon.com>
This commit is contained in:
co-authored by
Keavon Chambers
parent
c823016316
commit
e0ac073805
@@ -60,7 +60,7 @@ impl Default for Document {
|
||||
inputs: vec![NodeInput::value(TaggedValue::GraphicGroup(Default::default()), true), NodeInput::Network(concrete!(WasmEditorApi))],
|
||||
implementation: graph_craft::document::DocumentNodeImplementation::Network(NodeNetwork {
|
||||
inputs: vec![3, 0],
|
||||
outputs: vec![NodeOutput::new(4, 0)],
|
||||
outputs: vec![NodeOutput::new(3, 0)],
|
||||
nodes: [
|
||||
DocumentNode {
|
||||
name: "EditorApi".to_string(),
|
||||
@@ -82,16 +82,14 @@ impl Default for Document {
|
||||
implementation: DocumentNodeImplementation::Unresolved(NodeIdentifier::new("graphene_core::memo::MemoNode<_, _>")),
|
||||
..Default::default()
|
||||
},
|
||||
DocumentNode {
|
||||
name: "Conversion".to_string(),
|
||||
inputs: vec![NodeInput::Network(graphene_core::Type::Fn(Box::new(concrete!(Footprint)), Box::new(generic!(T))))],
|
||||
implementation: DocumentNodeImplementation::Unresolved(NodeIdentifier::new("graphene_core::ops::IntoNode<_, GraphicGroup>")),
|
||||
..Default::default()
|
||||
},
|
||||
DocumentNode {
|
||||
name: "RenderNode".to_string(),
|
||||
inputs: vec![NodeInput::node(0, 0), NodeInput::node(3, 0), NodeInput::node(2, 0)],
|
||||
implementation: DocumentNodeImplementation::Unresolved(NodeIdentifier::new("graphene_std::wasm_application_io::RenderNode<_, _>")),
|
||||
inputs: vec![
|
||||
NodeInput::node(0, 0),
|
||||
NodeInput::Network(graphene_core::Type::Fn(Box::new(concrete!(Footprint)), Box::new(generic!(T)))),
|
||||
NodeInput::node(2, 0),
|
||||
],
|
||||
implementation: DocumentNodeImplementation::Unresolved(NodeIdentifier::new("graphene_std::wasm_application_io::RenderNode<_, _, _>")),
|
||||
..Default::default()
|
||||
},
|
||||
]
|
||||
|
||||
@@ -290,7 +290,7 @@ impl core::fmt::Display for LayerNodeIdentifier {
|
||||
}
|
||||
|
||||
impl LayerNodeIdentifier {
|
||||
const ROOT: Self = LayerNodeIdentifier::new_unchecked(0);
|
||||
pub const ROOT: Self = LayerNodeIdentifier::new_unchecked(0);
|
||||
|
||||
/// Construct a [`LayerNodeIdentifier`] without checking if it is a layer node
|
||||
pub const fn new_unchecked(node_id: NodeId) -> Self {
|
||||
|
||||
Reference in New Issue
Block a user