You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
hexview/src/graphics.cpp

34 lines
596 B

#include <tickit.h>
#include <graphics.hpp>
static int on_geomchange(TickitWindow* win, TickitEventFlags flags, void* info, void* data)
{
tickit_window_expose(win, NULL);
gr::Context* ctx = (gr::Context*)data;
}
namespace gr
{
struct Context::_impl
{
Tickit* context;
TickitWindow* root;
};
Context::Context()
: impl(std::make_unique<_impl>())
{
impl->context = tickit_new_stdtty();
impl->root = tickit_get_rootwin(impl->context);
if(!impl->root) throw "couldn't create window.";
}
Context::~Context()
{
tickit_unref(impl->context);
}
}