did anyone else notice you can also drag the screen like you would on a tablet (also pg up/down forces a redraw that fixes tearing) The history navigation window would make a good template for bookmarking, but the fbtk needs to add a popup window (for right click menu to include bookmark/download/view source/copy/paste etc..., javascript alerts, and others - it may be already be possible using some css tricks and existing fbtk widgets.
the paths in the pet are required, don't move them from /usr/local/share/netsurf or you will get segfaults... and truetype fonts must be in /usr/share/fonts/default/TTF as:
NETSURF_FB_FONTPATH := /usr/share/fonts/default/TTF
NETSURF_FB_FONT_SANS_SERIF := DejaVuSans.ttf
NETSURF_FB_FONT_SANS_SERIF_BOLD := DejaVuSans-Bold.ttf
NETSURF_FB_FONT_SANS_SERIF_ITALIC := DejaVuSans-Oblique.ttf
NETSURF_FB_FONT_SANS_SERIF_ITALIC_BOLD := DejaVuSans-BoldOblique.ttf
NETSURF_FB_FONT_SERIF := DejaVuSerif.ttf
NETSURF_FB_FONT_SERIF_BOLD := DejaVuSerif-Bold.ttf
NETSURF_FB_FONT_MONOSPACE := DejaVuSansMono.ttf
NETSURF_FB_FONT_MONOSPACE_BOLD := DejaVuSansMono-Bold.ttf
NETSURF_FB_FONT_CURSIVE := Comic_Sans_MS.ttf
NETSURF_FB_FONT_FANTASY := Impact.ttf
to change default settings try the css files in /usr/local/share/netsurf (one of them controls ad blocking too)
here is the code I modified in gui.c (process_cmdline) for x and linux backend to go full screen ... (it was defaulting to sdl and 800x600x32) if anyone cared to comment - I was just shotgunning it and probably need to close the (temporary) xcb connection
Code: Select all
if (getenv("DISPLAY")){
#include <xcb/xcb.h>
fename = "x";
xcb_connection_t *c;
int32_t screen_number;
xcb_screen_t *screen;
c = xcb_connect (NULL, &screen_number );
screen = xcb_setup_roots_iterator(xcb_get_setup (c)).data;
if (screen){
fewidth = screen->width_in_pixels;
feheight = screen->height_in_pixels - 48 ; //handle tray
febpp = screen->root_depth;
}
}else{
#include <sys/ioctl.h>
#include <linux/fb.h>
fename = "linux";
struct fb_var_screeninfo variable_info;
//ioctl (open ("/dev/fb0", O_RDWR), FBIOGET_VSCREENINFO, &variable_info);
ioctl(STDOUT_FILENO, FBIOGET_VSCREENINFO, &variable_info);
fewidth = variable_info.xres;
feheight = variable_info.yres;
febpp = variable_info.bits_per_pixel;
}
if ((nsoption_charp(homepage_url) != NULL) &&
(nsoption_charp(homepage_url)[0] != '\0')) {
feurl = nsoption_charp(homepage_url);
} else {
feurl = NETSURF_HOMEPAGE;
}
any preferences for homepage_url / NETSURF_HOMEPAGE?
Edit: framebuffer/fbtk/event.c should have this keymap instead:
static int sh_keymap[] = {
/* 0 1 2 3 4 5 6 7 8 9 */
-1, -1, -1, -1, -1, -1, -1, -1, 8, 9, /* 0 - 9 */
-1, -1, -1, 13, -1, -1, -1, -1, -1, -1, /* 10 - 19 */
-1, -1, -1, -1, -1, -1, -1, 27, -1, -1, /* 20 - 29 */
-1, -1, ' ', '!', '"', '~', '$', -1, '&', '"', /* 30 - 39 */
'(', ')', '*', '+', '<', '_', '>', '?', ')', '!', /* 40 - 49 */
'@', '#', '$', '%', '^', '&', '*', '(', ';', ':', /* 50 - 59 */
'<', '+', '>', '?', '@', -1, -1, -1, -1, -1, /* 60 - 69 */
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, /* 70 - 79 */
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, /* 80 - 89 */
-1, '{', '|', '}', '~', '_', '~', 'A', 'B', 'C', /* 90 - 99 */
'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', /* 100 - 109 */
'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', /* 110 - 119 */
'X', 'Y', 'Z', -1, -1, -1, -1, -1, -1, -1, /* 120 - 129 */
};