commit neovim-gtk for openSUSE:Factory

2020-01-26 Thread root
Hello community,

here is the log from the commit of package neovim-gtk for openSUSE:Factory 
checked in at 2020-01-27 00:22:51

Comparing /work/SRC/openSUSE:Factory/neovim-gtk (Old)
 and  /work/SRC/openSUSE:Factory/.neovim-gtk.new.26092 (New)


Package is "neovim-gtk"

Mon Jan 27 00:22:51 2020 rev:3 rq:767261 version:0.2.0+git.1579960262.0af8952

Changes:

--- /work/SRC/openSUSE:Factory/neovim-gtk/neovim-gtk.changes2019-12-05 
17:34:16.269448755 +0100
+++ /work/SRC/openSUSE:Factory/.neovim-gtk.new.26092/neovim-gtk.changes 
2020-01-27 00:23:23.361523899 +0100
@@ -1,0 +2,7 @@
+Sat Jan 25 23:01:54 UTC 2020 - Matej Cepl 
+
+- Update to version 0.2.0+git.1579960262.0af8952:
+  * fix build
+  * Fix mouse selection while dragging with leftclick, fixes #185
+
+---

Old:

  neovim-gtk-0.2.0+git.1575188169.31fd179.tar.xz

New:

  neovim-gtk-0.2.0+git.1579960262.0af8952.tar.xz



Other differences:
--
++ neovim-gtk.spec ++
--- /var/tmp/diff_new_pack.YqUDuQ/_old  2020-01-27 00:23:25.161524747 +0100
+++ /var/tmp/diff_new_pack.YqUDuQ/_new  2020-01-27 00:23:25.165524749 +0100
@@ -1,7 +1,7 @@
 #
 # spec file for package neovim-gtk
 #
-# Copyright (c) 2019 SUSE LLC
+# Copyright (c) 2020 SUSE LLC
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -20,7 +20,7 @@
 %define binname nvim-gtk
 
 Name:   neovim-gtk
-Version:0.2.0+git.1575188169.31fd179
+Version:0.2.0+git.1579960262.0af8952
 Release:0
 Summary:GTK UI for Neovim
 License:GPL-3.0-only

++ _servicedata ++
--- /var/tmp/diff_new_pack.YqUDuQ/_old  2020-01-27 00:23:25.201524766 +0100
+++ /var/tmp/diff_new_pack.YqUDuQ/_new  2020-01-27 00:23:25.201524766 +0100
@@ -1,6 +1,6 @@
 
   
 https://github.com/daa84/neovim-gtk
-31fd179c9a772104c601ab5cea16e3ad42ec1f4a
+0af8952171c5375a4435cf3790e08c3b9ee29e8d
   
 
\ No newline at end of file

++ neovim-gtk-0.2.0+git.1575188169.31fd179.tar.xz -> 
neovim-gtk-0.2.0+git.1579960262.0af8952.tar.xz ++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/neovim-gtk-0.2.0+git.1575188169.31fd179/src/shell.rs 
new/neovim-gtk-0.2.0+git.1579960262.0af8952/src/shell.rs
--- old/neovim-gtk-0.2.0+git.1575188169.31fd179/src/shell.rs2019-12-01 
09:16:09.0 +0100
+++ new/neovim-gtk-0.2.0+git.1579960262.0af8952/src/shell.rs2020-01-25 
14:51:02.0 +0100
@@ -552,6 +552,9 @@
 mouse_pressed: bool,
 scroll_delta: (f64, f64),
 
+// previous editor position (col, row)
+prev_pos: (u64, u64),
+
 mouse_cursor: MouseCursor,
 }
 
@@ -560,6 +563,7 @@
 UiState {
 mouse_pressed: false,
 scroll_delta: (0.0, 0.0),
+prev_pos: (0, 0),
 
 mouse_cursor: MouseCursor::None,
 }
@@ -1047,14 +1051,7 @@
 
 fn mouse_input(shell: &mut State, input: &str, state: ModifierType, position: 
(f64, f64)) {
 if let Some(mut nvim) = shell.try_nvim() {
-let &CellMetrics {
-line_height,
-char_width,
-..
-} = shell.render_state.borrow().font_ctx.cell_metrics();
-let (x, y) = position;
-let col = (x / char_width).trunc() as u64;
-let row = (y / line_height).trunc() as u64;
+let (col, row) = mouse_coordinates_to_nvim(shell, position);
 let input_str = format!("{}<{},{}>", keyval_to_input_string(input, 
state), col, row);
 
 nvim.input(&input_str)
@@ -1062,6 +1059,21 @@
 }
 }
 
+/**
+ * Translate gtk mouse event coordinates to nvim (col, row).
+ */
+fn mouse_coordinates_to_nvim(shell: &State, position: (f64, f64)) -> (u64, 
u64) {
+let &CellMetrics {
+line_height,
+char_width,
+..
+} = shell.render_state.borrow().font_ctx.cell_metrics();
+let (x, y) = position;
+let col = (x / char_width).trunc() as u64;
+let row = (y / line_height).trunc() as u64;
+(col, row)
+}
+
 fn gtk_button_release(shell: &mut State, ui_state: &mut UiState, ev: 
&EventButton) -> Inhibit {
 ui_state.mouse_pressed = false;
 
@@ -1079,7 +1091,15 @@
 
 fn gtk_motion_notify(shell: &mut State, ui_state: &mut UiState, ev: 
&EventMotion) -> Inhibit {
 if shell.mouse_enabled && ui_state.mouse_pressed {
-mouse_input(shell, "LeftDrag", ev.get_state(), ev.get_position());
+let ev_pos = ev.get_position();
+let pos = mouse_coordinates_to_nvim(shell, ev_pos);
+
+// if we fire LeftDrag on the same coordinates multiple times, then
+// we get: https://github.com/daa84/neovim-gtk/issues/185
+ 

commit neovim-gtk for openSUSE:Factory

2019-12-05 Thread root
Hello community,

here is the log from the commit of package neovim-gtk for openSUSE:Factory 
checked in at 2019-12-05 17:34:01

Comparing /work/SRC/openSUSE:Factory/neovim-gtk (Old)
 and  /work/SRC/openSUSE:Factory/.neovim-gtk.new.4691 (New)


Package is "neovim-gtk"

Thu Dec  5 17:34:01 2019 rev:2 rq:754205 version:0.2.0+git.1575188169.31fd179

Changes:

--- /work/SRC/openSUSE:Factory/neovim-gtk/neovim-gtk.changes2019-11-30 
10:38:56.880160899 +0100
+++ /work/SRC/openSUSE:Factory/.neovim-gtk.new.4691/neovim-gtk.changes  
2019-12-05 17:34:16.269448755 +0100
@@ -1,0 +2,16 @@
+Wed Dec 04 23:32:43 UTC 2019 - Matej Cepl 
+
+- Update to version 0.2.0+git.1575188169.31fd179:
+  * Update text color under cursor
+  * Update README.md
+  * Update rust.yml
+  * Create rust.yml
+  * Major update of dependencies
+  * Cleanup
+  * Create FUNDING.yml
+  * Update README.md
+  * Fix background rendering (#208)
+  * Use f64 instead of i32 for width caulculation (#208)
+  * Try to fix render issues due to changes in pango_1.44 (#208)
+
+---

Old:

  neovim-gtk-0.2.0+git.1570090897.3ace1d2.tar.xz

New:

  neovim-gtk-0.2.0+git.1575188169.31fd179.tar.xz



Other differences:
--
++ neovim-gtk.spec ++
--- /var/tmp/diff_new_pack.vaZl6p/_old  2019-12-05 17:34:17.509448580 +0100
+++ /var/tmp/diff_new_pack.vaZl6p/_new  2019-12-05 17:34:17.509448580 +0100
@@ -1,7 +1,7 @@
 #
 # spec file for package neovim-gtk
 #
-# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2019 SUSE LLC
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -12,26 +12,26 @@
 # license that conforms to the Open Source Definition (Version 1.9)
 # published by the Open Source Initiative.
 
-# Please submit bugfixes or comments via http://bugs.opensuse.org/
+# Please submit bugfixes or comments via https://bugs.opensuse.org/
 #
 
+
 %define icondir %{_datadir}/icons
 %define binname nvim-gtk
 
-
 Name:   neovim-gtk
-Version:0.2.0+git.1570090897.3ace1d2
+Version:0.2.0+git.1575188169.31fd179
 Release:0
 Summary:GTK UI for Neovim
-License:GPL-3.0
+License:GPL-3.0-only
 Group:  Productivity/Text/Editors
-Url:https://github.com/daa84/neovim-gtk
+URL:https://github.com/daa84/neovim-gtk
 Source0:neovim-gtk-%{version}.tar.xz
 Source1:neovim-gtk-vendor.tar.xz
 BuildRequires:  cargo
-BuildRequires:  pango-devel
 BuildRequires:  gtk3-devel
 BuildRequires:  hicolor-icon-theme
+BuildRequires:  pango-devel
 
 %description
 GTK UI for Neovim written in Rust using gtk-rs bindings. With ligatures

++ _servicedata ++
--- /var/tmp/diff_new_pack.vaZl6p/_old  2019-12-05 17:34:17.537448576 +0100
+++ /var/tmp/diff_new_pack.vaZl6p/_new  2019-12-05 17:34:17.537448576 +0100
@@ -1,6 +1,6 @@
 
   
 https://github.com/daa84/neovim-gtk
-27d056bb00e9730f6e07e60f5a7bad75967dc22a
+31fd179c9a772104c601ab5cea16e3ad42ec1f4a
   
 
\ No newline at end of file

++ neovim-gtk-0.2.0+git.1570090897.3ace1d2.tar.xz -> 
neovim-gtk-0.2.0+git.1575188169.31fd179.tar.xz ++
 2176 lines of diff (skipped)

++ neovim-gtk-vendor.tar.xz ++
/work/SRC/openSUSE:Factory/neovim-gtk/neovim-gtk-vendor.tar.xz 
/work/SRC/openSUSE:Factory/.neovim-gtk.new.4691/neovim-gtk-vendor.tar.xz 
differ: char 27, line 1