Set text fill color to the primary color (#521)

* Fix text has no fill

* Use primary color for text fill

* Use correct text color when editing

* Change fallback text color to gray
This commit is contained in:
Paul Kupper
2022-02-07 20:58:22 +01:00
committed by Keavon Chambers
parent 5ea4654f53
commit cb9a37b638
3 changed files with 7 additions and 3 deletions
+2 -1
View File
@@ -9,6 +9,7 @@ use crate::misc::{HintData, HintGroup, HintInfo, KeysGroup};
use crate::viewport_tools::tool::{DocumentToolData, Fsm, ToolActionHandlerData};
use glam::{DAffine2, DVec2};
use graphene::color::Color;
use graphene::intersection::Quad;
use graphene::layers::style::{self, Fill, Stroke};
use graphene::Operation;
@@ -253,7 +254,7 @@ impl Fsm for TextToolFsmState {
transform: DAffine2::ZERO.to_cols_array(),
insert_index: -1,
text: r#""#.to_string(),
style: style::PathStyle::new(Some(style::Stroke::new(tool_data.primary_color, 0.)), None),
style: style::PathStyle::new(None, Some(Fill::new(tool_data.primary_color))),
size: font_size as f64,
}
.into(),