Skip to content

Commit

Permalink
adapt to notcurses 2.2.9
Browse files Browse the repository at this point in the history
  • Loading branch information
dankamongmen committed May 4, 2021
1 parent 8a895f9 commit dbb3357
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Expand Up @@ -36,7 +36,7 @@ pkg_check_modules(LIBREADLINE REQUIRED readline)
pkg_check_modules(LIBUDEV REQUIRED libudev>=175)
pkg_check_modules(LIBZ REQUIRED zlib>=1.2.11)
if(${USE_NOTCURSES})
find_package(Notcurses 2.0.7 CONFIG)
find_package(Notcurses 2.2.9 CONFIG)
set_package_properties(Notcurses PROPERTIES TYPE REQUIRED)
endif()

Expand Down
2 changes: 1 addition & 1 deletion README.md
Expand Up @@ -32,7 +32,7 @@ sockets. Packet transmission requires at least a 2.6.29 kernel.

The line-based UI (`omphalos-readline`) requires GNU Readline.

The fullscreen UI (`omphalos`) requires Notcurses 2.0.7+.
The fullscreen UI (`omphalos`) requires Notcurses 2.2.9+.

arp-scan's `get-oui` program is used to build the IANA OUI file.

Expand Down
14 changes: 7 additions & 7 deletions src/ui/notcurses/iface.c
Expand Up @@ -716,10 +716,10 @@ void iface_box(const interface *i, const iface_state *is, struct ncplane *n,
ncplane_set_styles(n, attrs);
ncplane_set_fg_rgb(n, bcolor);
ncplane_cursor_move_yx(n, 0, 1);
cell c = CELL_TRIVIAL_INITIALIZER;
cell_load(n, &c, "─");
cell_set_fg_rgb(&c, bcolor);
cell_set_styles(&c, attrs);
nccell c = CELL_TRIVIAL_INITIALIZER;
nccell_load(n, &c, "─");
nccell_set_fg_rgb(&c, bcolor);
nccell_set_styles(&c, attrs);
ncplane_hline(n, &c, cols - 3);
ncplane_putegc_yx(n, 0, cols - 1, "╮", NULL);
ncplane_off_styles(n, NCSTYLE_REVERSE);
Expand Down Expand Up @@ -765,10 +765,10 @@ void iface_box(const interface *i, const iface_state *is, struct ncplane *n,
ncplane_off_styles(n, NCSTYLE_REVERSE);
attrs = NCSTYLE_BOLD | (active ? NCSTYLE_REVERSE : 0);
ncplane_set_styles(n, attrs);
cell_set_fg_rgb(&c, bcolor);
cell_set_styles(&c, attrs);
nccell_set_fg_rgb(&c, bcolor);
nccell_set_styles(&c, attrs);
ncplane_hline(n, &c, cols - 3);
cell_release(n, &c);
nccell_release(n, &c);
ncplane_putegc_yx(n, rows - 1, cols - 1, "╯", NULL);
ncplane_printf_yx(n, rows - 1, 2, "[");
ncplane_set_fg_rgb(n, hcolor);
Expand Down

0 comments on commit dbb3357

Please sign in to comment.