Skip to content

Commit

Permalink
Error fix sub_window.rs
Browse files Browse the repository at this point in the history
error fix for lines 301 to 304
  • Loading branch information
CaptainMirage authored Nov 27, 2024
1 parent b831b5f commit e9d1cd5
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion druid/examples/sub_window.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,13 @@
// SPDX-License-Identifier: Apache-2.0

//! Example of sub windows.
// dependencies
// druid = "0.8.3"
// druid-shell = "0.8.3"
// piet = "0.7.0"
// instant = "0.1.13"
// tracing = "0.1.40"

// On Windows platform, don't show a console when opening the app.
#![windows_subsystem = "windows"]
Expand All @@ -19,7 +26,10 @@ use druid::{
use druid_shell::piet::Text;
use druid_shell::{Screen, WindowLevel};
use instant::{Duration, Instant};
use piet_common::{TextLayout, TextLayoutBuilder};
use druid::piet::{TextLayout, TextLayoutBuilder};
// not sure why but using the piet package instead of
// piet-common fixes an error in lines 301 to 304
// OLD - use piet_common::{TextLayout, TextLayoutBuilder};

const VERTICAL_WIDGET_SPACING: f64 = 20.0;
const TEXT_BOX_WIDTH: f64 = 200.0;
Expand Down

0 comments on commit e9d1cd5

Please sign in to comment.