mirror of
https://github.com/YGGverse/Yoda.git
synced 2026-03-31 16:45:27 +00:00
temporary disable libspelling, use latest gtk api versions
This commit is contained in:
parent
2014f5e421
commit
6d6b1bc8c8
3 changed files with 16 additions and 16 deletions
12
Cargo.toml
12
Cargo.toml
|
|
@ -12,12 +12,12 @@ repository = "https://github.com/YGGverse/Yoda"
|
||||||
|
|
||||||
[dependencies.adw]
|
[dependencies.adw]
|
||||||
package = "libadwaita"
|
package = "libadwaita"
|
||||||
version = "0.7.2"
|
version = "0.8.0"
|
||||||
features = ["v1_5"]
|
features = ["v1_5"]
|
||||||
|
|
||||||
[dependencies.gtk]
|
[dependencies.gtk]
|
||||||
package = "gtk4"
|
package = "gtk4"
|
||||||
version = "0.9.7"
|
version = "0.10.0"
|
||||||
features = ["gnome_46"]
|
features = ["gnome_46"]
|
||||||
|
|
||||||
[dependencies.sqlite]
|
[dependencies.sqlite]
|
||||||
|
|
@ -26,17 +26,17 @@ version = "0.37.0"
|
||||||
|
|
||||||
[dependencies.sourceview]
|
[dependencies.sourceview]
|
||||||
package = "sourceview5"
|
package = "sourceview5"
|
||||||
version = "0.9.1"
|
version = "0.10.0"
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
ansi-parser = "0.9.1"
|
ansi-parser = "0.9.1"
|
||||||
anyhow = "1.0.97"
|
anyhow = "1.0.97"
|
||||||
async-channel = "2.5.0"
|
async-channel = "2.5.0"
|
||||||
ggemini = "0.19.0"
|
ggemini = "0.19.0"
|
||||||
ggemtext = "0.6.0"
|
ggemtext = "0.7.0"
|
||||||
indexmap = "2.7.0"
|
indexmap = "2.7.0"
|
||||||
itertools = "0.14.0"
|
itertools = "0.14.0"
|
||||||
libspelling = "0.4.0"
|
# libspelling = "0.4.0"
|
||||||
maxminddb = "0.26.0"
|
maxminddb = "0.26.0"
|
||||||
openssl = "0.10.72"
|
openssl = "0.10.72"
|
||||||
plurify = "0.2.0"
|
plurify = "0.2.0"
|
||||||
|
|
@ -47,5 +47,5 @@ syntect = "5.2.0"
|
||||||
# development
|
# development
|
||||||
[patch.crates-io]
|
[patch.crates-io]
|
||||||
ggemini = { git = "https://github.com/YGGverse/ggemini.git" }
|
ggemini = { git = "https://github.com/YGGverse/ggemini.git" }
|
||||||
# ggemtext = { git = "https://github.com/YGGverse/ggemtext.git" }
|
ggemtext = { git = "https://github.com/YGGverse/ggemtext.git" }
|
||||||
# plurify = { git = "https://github.com/YGGverse/plurify.git" }
|
# plurify = { git = "https://github.com/YGGverse/plurify.git" }
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ use gtk::{
|
||||||
glib::GString,
|
glib::GString,
|
||||||
prelude::{TextBufferExt, TextViewExt, WidgetExt},
|
prelude::{TextBufferExt, TextViewExt, WidgetExt},
|
||||||
};
|
};
|
||||||
use libspelling::{Checker, TextBufferAdapter};
|
//use libspelling::{Checker, TextBufferAdapter};
|
||||||
use sourceview::Buffer;
|
use sourceview::Buffer;
|
||||||
|
|
||||||
const MARGIN: i32 = 8;
|
const MARGIN: i32 = 8;
|
||||||
|
|
@ -22,16 +22,16 @@ impl Form for TextView {
|
||||||
let buffer = Buffer::builder().build();
|
let buffer = Buffer::builder().build();
|
||||||
|
|
||||||
// Init [libspelling](https://gitlab.gnome.org/GNOME/libspelling)
|
// Init [libspelling](https://gitlab.gnome.org/GNOME/libspelling)
|
||||||
let checker = Checker::default();
|
/*let checker = Checker::default();
|
||||||
let adapter = TextBufferAdapter::new(&buffer, &checker);
|
let adapter = TextBufferAdapter::new(&buffer, &checker);
|
||||||
adapter.set_enabled(true);
|
adapter.set_enabled(true);*/
|
||||||
|
|
||||||
// Init main widget
|
// Init main widget
|
||||||
let text_view = TextView::builder()
|
let text_view = TextView::builder()
|
||||||
.bottom_margin(MARGIN)
|
.bottom_margin(MARGIN)
|
||||||
.buffer(&buffer)
|
.buffer(&buffer)
|
||||||
.css_classes(["frame", "view"])
|
.css_classes(["frame", "view"])
|
||||||
.extra_menu(&adapter.menu_model())
|
//.extra_menu(&adapter.menu_model())
|
||||||
.left_margin(MARGIN)
|
.left_margin(MARGIN)
|
||||||
.margin_bottom(MARGIN / 4)
|
.margin_bottom(MARGIN / 4)
|
||||||
.right_margin(MARGIN)
|
.right_margin(MARGIN)
|
||||||
|
|
@ -39,7 +39,7 @@ impl Form for TextView {
|
||||||
.wrap_mode(WrapMode::Word)
|
.wrap_mode(WrapMode::Word)
|
||||||
.build();
|
.build();
|
||||||
|
|
||||||
text_view.insert_action_group("spelling", Some(&adapter));
|
//text_view.insert_action_group("spelling", Some(&adapter));
|
||||||
text_view.set_size_request(-1, 38); // @TODO [#635](https://gitlab.gnome.org/GNOME/pygobject/-/issues/635)
|
text_view.set_size_request(-1, 38); // @TODO [#635](https://gitlab.gnome.org/GNOME/pygobject/-/issues/635)
|
||||||
|
|
||||||
// Init events
|
// Init events
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
use gtk::{TextView, WrapMode, prelude::WidgetExt};
|
use gtk::{TextView, WrapMode, prelude::WidgetExt};
|
||||||
use libspelling::{Checker, TextBufferAdapter};
|
//use libspelling::{Checker, TextBufferAdapter};
|
||||||
use sourceview::Buffer;
|
use sourceview::Buffer;
|
||||||
|
|
||||||
pub trait Form {
|
pub trait Form {
|
||||||
|
|
@ -15,9 +15,9 @@ impl Form for TextView {
|
||||||
let buffer = Buffer::builder().build();
|
let buffer = Buffer::builder().build();
|
||||||
|
|
||||||
// Init [libspelling](https://gitlab.gnome.org/GNOME/libspelling)
|
// Init [libspelling](https://gitlab.gnome.org/GNOME/libspelling)
|
||||||
let checker = Checker::default();
|
/*let checker = Checker::default();
|
||||||
let adapter = TextBufferAdapter::new(&buffer, &checker);
|
let adapter = TextBufferAdapter::new(&buffer, &checker);
|
||||||
adapter.set_enabled(true);
|
adapter.set_enabled(true);*/
|
||||||
|
|
||||||
// Init main widget
|
// Init main widget
|
||||||
|
|
||||||
|
|
@ -27,7 +27,7 @@ impl Form for TextView {
|
||||||
.bottom_margin(MARGIN)
|
.bottom_margin(MARGIN)
|
||||||
.buffer(&buffer)
|
.buffer(&buffer)
|
||||||
.css_classes(["frame", "view"])
|
.css_classes(["frame", "view"])
|
||||||
.extra_menu(&adapter.menu_model())
|
//.extra_menu(&adapter.menu_model())
|
||||||
.left_margin(MARGIN)
|
.left_margin(MARGIN)
|
||||||
.right_margin(MARGIN)
|
.right_margin(MARGIN)
|
||||||
.top_margin(MARGIN)
|
.top_margin(MARGIN)
|
||||||
|
|
@ -35,7 +35,7 @@ impl Form for TextView {
|
||||||
.build()
|
.build()
|
||||||
};
|
};
|
||||||
|
|
||||||
text_view.insert_action_group("spelling", Some(&adapter));
|
//text_view.insert_action_group("spelling", Some(&adapter));
|
||||||
text_view.set_size_request(-1, 38); // @TODO [#635](https://gitlab.gnome.org/GNOME/pygobject/-/issues/635)
|
text_view.set_size_request(-1, 38); // @TODO [#635](https://gitlab.gnome.org/GNOME/pygobject/-/issues/635)
|
||||||
|
|
||||||
// Init events
|
// Init events
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue