Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remove some debug output #601

Merged
merged 1 commit into from
Sep 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions crates/gosub_html5/src/parser.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4345,11 +4345,8 @@ impl<'chars> Html5Parser<'chars> {
}
}
};
println!("loading external stylesheet: {}", css_url);

if let Some(stylesheet) = self.load_external_stylesheet(CssOrigin::Author, css_url)
{
println!("success: loaded external stylesheet");
self.document.get_mut().stylesheets.push(stylesheet);
} else {
println!("failed loading stylesheet")
Expand Down
2 changes: 0 additions & 2 deletions crates/gosub_styling/src/property_definitions.rs
Original file line number Diff line number Diff line change
Expand Up @@ -353,8 +353,6 @@ pub static CSS_DEFINITIONS: LazyLock<CssDefinitions, fn() -> CssDefinitions> =

/// Parses the internal CSS definition file
fn pars_definition_files() -> CssDefinitions {
println!("parse_definition_files");

// parse all syntax, so we can use them in the properties
let contents = include_str!("../resources/definitions/definitions_values.json");
let json: serde_json::Value =
Expand Down
19 changes: 0 additions & 19 deletions crates/gosub_taffy/src/compute/inline.rs
Original file line number Diff line number Diff line change
Expand Up @@ -265,11 +265,6 @@ pub fn compute_inline_layout<LT: LayoutTree<TaffyLayouter>>(

let run_y = run.baseline();

if current_node_id.into() == 161 || current_node_id.into() == 163 {
println!("current_node_id: {:?}", current_node_id.into());
println!("first glyph: {:?}", glyphs.get(2));
}

current_glyph_idx += glyphs.len();

if current_glyph_idx > current_to {
Expand Down Expand Up @@ -308,20 +303,6 @@ pub fn compute_inline_layout<LT: LayoutTree<TaffyLayouter>>(
width: size.width,
height: size.height,
};

if current_node_id.into() == 160 {
println!("current_node_id: {:?}", current_node_id.into());
println!("size: {:?}", size);

println!(
"location: {:?}",
Point {
x: run.offset(),
y: run_y,
}
);
}

tree.set_unrounded_layout(
NodeId::new(current_node_id.into()),
&Layout {
Expand Down
2 changes: 0 additions & 2 deletions crates/gosub_taffy/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -122,8 +122,6 @@ impl Layouter for TaffyLayouter {
root: LT::NodeId,
space: SizeU32,
) -> Result<()> {
println!("space: {:?}", space);

let size = taffy::Size {
width: AvailableSpace::Definite(space.width as f32),
height: AvailableSpace::Definite(space.height as f32),
Expand Down
8 changes: 0 additions & 8 deletions crates/gosub_useragent/src/window.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
use anyhow::anyhow;
use image::imageops::FilterType;
use image::GenericImageView;
use log::warn;
use std::cell::LazyCell;
use std::ops::Deref;
Expand Down Expand Up @@ -34,13 +33,10 @@ static ICON: LazyCell<Icon> = LazyCell::new(|| {
};


println!("size: {:?}", img.dimensions());
let height = img.height() / (img.width() / 256);

let rgba = img.resize_exact(256, height, FilterType::Nearest).to_rgba8();

println!("size: {:?}", rgba.dimensions());


Icon::from_rgba(rgba.to_vec(), rgba.width(), rgba.height()).unwrap_or(
Icon::from_rgba(vec![], 0, 0).unwrap()
Expand Down Expand Up @@ -79,11 +75,9 @@ impl<'a, D: SceneDrawer<B, L, LT>, B: RenderBackend, L: Layouter, LT: LayoutTree
}

pub fn resumed(&mut self, backend: &mut B) -> Result<()> {
println!("Resuming window...");
if !matches!(self.state, WindowState::Suspended) {
return Ok(());
};
println!("Resuming window");

let size = self.window.inner_size();
let size = SizeU32::new(size.width, size.height);
Expand Down Expand Up @@ -141,8 +135,6 @@ fn create_window(event_loop: &ActiveEventLoop) -> Result<Arc<WinitWindow>> {
.with_window_icon(Some(ICON.with(|icon| icon.deref().clone())))
.with_inner_size(LogicalSize::new(1920, 1080));

println!("icon: {:?}", attributes.window_icon.is_some());

event_loop
.create_window(attributes)
.map_err(|e| anyhow!(e.to_string()))
Expand Down
10 changes: 0 additions & 10 deletions crates/gosub_vello/src/render.rs
Original file line number Diff line number Diff line change
Expand Up @@ -148,16 +148,6 @@ impl Renderer {
chosen_adapter
});

{
let instance = Instance::new(Default::default());

let adapters = instance.enumerate_adapters(Backends::all());

for adapter in adapters {
println!("Adapter: {:?}", adapter.get_info());
}
}

#[cfg(target_arch = "wasm32")]
let mut adapter = None;

Expand Down