Skip to content

Commit

Permalink
Add set_text() API on the window to update the text view
Browse files Browse the repository at this point in the history
  • Loading branch information
jonas2515 committed Dec 8, 2024
1 parent 8a92311 commit a175070
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/window.rs
Original file line number Diff line number Diff line change
Expand Up @@ -88,4 +88,10 @@ impl AardvarkWindow {
.property("application", application)
.build()
}

pub fn set_text(&self, text: &str) {
let window = self.imp();
let buffer = window.text_view.buffer();
buffer.set_text(text);
}
}

0 comments on commit a175070

Please sign in to comment.