Migrate to new libs versions

This commit is contained in:
daa
2017-05-21 15:47:29 +03:00
parent c3a22dccf9
commit 243df1cb72
4 changed files with 53 additions and 52 deletions

View File

@@ -4,7 +4,7 @@ use std::sync;
use std::sync::Arc;
use cairo;
use pangocairo as pc;
use pangocairo::CairoContextExt;
use pango;
use pango::FontDescription;
use gdk::{ModifierType, EventConfigure, EventButton, EventMotion, EventType, EventScroll};
@@ -480,7 +480,7 @@ fn draw_backgound(state: &State,
}
fn draw(state: &State, ctx: &cairo::Context) {
let layout = pc::create_layout(ctx);
let layout = ctx.create_pango_layout();
let mut desc = state.create_pango_font();
let mut buf = String::with_capacity(4);
@@ -553,8 +553,8 @@ fn draw(state: &State, ctx: &cairo::Context) {
}
ctx.set_source_rgb(fg.0, fg.1, fg.2);
pc::update_layout(ctx, &layout);
pc::show_layout(ctx, &layout);
ctx.update_pango_layout(&layout);
ctx.show_pango_layout(&layout);
}
if cell.attrs.underline || cell.attrs.undercurl {
@@ -609,7 +609,7 @@ fn update_font_description(desc: &mut FontDescription, attrs: &Attrs) {
}
fn calc_char_bounds(shell: &State, ctx: &cairo::Context) -> (i32, i32) {
let layout = pc::create_layout(ctx);
let layout = ctx.create_pango_layout();
let desc = shell.create_pango_font();
layout.set_font_description(Some(&desc));

View File

@@ -74,7 +74,7 @@ fn show_not_saved_dlg(comps: &UiMutex<Components>,
fn get_changed_buffers(shell: &Shell) -> Result<Vec<String>, CallError> {
let state = shell.state.borrow();
let mut nvim = state.nvim();
let buffers = nvim.get_buffers().unwrap();
let buffers = nvim.list_bufs().unwrap();
Ok(buffers
.iter()