27#include <FL/Fl_Widget.H>
28#include <FL/Fl_Double_Window.H>
29#include <FL/Fl_Wizard.H>
31#include <FL/Fl_Pack.H>
32#include <FL/Fl_Scroll.H>
56#define DEFAULT_TAB_LABEL "-.new.-"
59#define BW2UI(bw) ((UI*)((bw)->ui))
89class CustTabButton :
public Fl_Button {
94 CustTabButton (
int x,
int y,
int w,
int h,
const char* label = 0) :
95 Fl_Button (x,y,w,h,label) { ui_ = NULL; focus_num_ = 0; };
96 void ui(
UI *pui) { ui_ = pui; }
97 UI *ui(
void) {
return ui_; }
98 void focus_num(
uint_t fn) { focus_num_ = fn; }
99 uint_t focus_num(
void) {
return focus_num_; }
102static int btn_cmp(
const void *p1,
const void *p2)
104 return ((*(CustTabButton *
const *)p1)->focus_num() -
105 (*(CustTabButton *
const *)p2)->focus_num() );
111class CustTabs :
public Fl_Group {
113 int tab_w, tab_h, ctab_h, btn_w, ctl_w;
120 void update_pack_offset(
void);
121 void resize(
int x,
int y,
int w,
int h)
122 { Fl_Group::resize(x,y,w,h); update_pack_offset(); }
123 int get_btn_idx(
UI *ui);
124 void increase_focus_counter() {
125 if (focus_counter < UINT_MAX)
129 CustTabButton **btns =
dNew(CustTabButton*, num_tabs());
130 for (
int i = 0; i < num_tabs(); ++i)
131 btns[i] = (CustTabButton*)Pack->child(i);
132 qsort(btns, num_tabs(),
sizeof(CustTabButton *),
btn_cmp);
134 for (
int i = 0; i < num_tabs(); ++i)
135 btns[i]->focus_num(focus_counter++);
141 CustTabs (
int ww,
int wh,
int th,
const char *lbl=0) :
142 Fl_Group(0,0,ww,th,lbl) {
145 tab_w = 50, tab_h = th, ctab_h = 1, btn_w = 20, ctl_w = 1*btn_w+2;
146 resize(0,0,ww,ctab_h);
148 Scroll =
new Fl_Scroll(0,0,ww-ctl_w,ctab_h);
150 Scroll->box(FL_NO_BOX);
151 Pack =
new Fl_Pack(0,0,ww-ctl_w,tab_h);
152 Pack->type(Fl_Pack::HORIZONTAL);
153 Pack->box(FL_NO_BOX);
159 Control =
new Fl_Group(ww-ctl_w,0,ctl_w,ctab_h);
160 CloseBtn =
new CustButton(ww-ctl_w+2,0,btn_w,ctab_h,
"X");
161 CloseBtn->box(FL_THIN_UP_BOX);
162 CloseBtn->clear_visible_focus();
164 "Close current tab.\nor Right-click tab label to close." :
165 "Close current tab.\nor Middle-click tab label to close.");
173 Wizard =
new Fl_Wizard(0,ctab_h,ww,wh-ctab_h);
174 Wizard->box(FL_NO_BOX);
178 UI *add_new_tab(
UI *old_ui,
int focus);
179 void remove_tab(
UI *ui);
180 Fl_Wizard *wizard(
void) {
return Wizard; }
181 int num_tabs() {
return (Pack ? Pack->children() : 0); }
182 void switch_tab(CustTabButton *cbtn);
185 void set_tab_label(
UI *ui,
const char *title);
193 CustTabButton *btn = (CustTabButton*) w;
194 CustTabs *tabs = (CustTabs*) cb_data;
195 int b = Fl::event_button();
197 if (b == FL_LEFT_MOUSE) {
198 tabs->switch_tab(btn);
211 CustTabs *tabs = (CustTabs*) cb_data;
212 int b = Fl::event_button();
214 if (b == FL_LEFT_MOUSE) {
219int CustTabs::handle(
int e)
223 _MSG(
"CustTabs::handle e=%s\n", fl_eventnames[e]);
224 if (e == FL_KEYBOARD) {
226 }
else if (e == FL_SHORTCUT) {
227 UI *ui = (
UI*)wizard()->value();
232 _MSG(
"CustTabs::handle KEYS_NOP\n");
254 int dx = Fl::event_dx();
255 int dy = Fl::event_dy();
256 int dir = dy ? dy : dx;
269 return (ret) ? ret : Fl_Group::handle(e);
275UI *CustTabs::add_new_tab(
UI *old_ui,
int focus)
277 if (num_tabs() == 1) {
280 Wizard->resize(0,ctab_h,Wizard->w(),
window()->h()-ctab_h);
281 resize(0,0,
window()->w(),ctab_h);
283 {
int w = 0, h; Pack->child(0)->measure_label(w, h);
284 Pack->child(0)->size(w+14,ctab_h);}
285 Pack->child(0)->show();
293 new_ui->resize(0,ctab_h,Wizard->w(),Wizard->h());
298 CustTabButton *btn =
new CustTabButton(num_tabs()*tab_w,0,tab_w,ctab_h);
299 btn->align(FL_ALIGN_INSIDE);
300 btn->labelsize(btn->labelsize()-2);
302 btn->clear_visible_focus();
303 btn->box(FL_GTK_THIN_UP_BOX);
314 increase_focus_counter();
315 btn->focus_num(focus_counter);
317 if (num_tabs() == 2) {
324 update_pack_offset();
332void CustTabs::remove_tab(
UI *ui)
337 int act_idx = get_btn_idx((
UI*)Wizard->value());
339 int rm_idx = get_btn_idx(ui);
340 btn = (CustTabButton*)Pack->child(rm_idx);
342 if (act_idx == rm_idx) {
344 CustTabButton *fbtn = NULL;
345 for (
int i = 0; i < num_tabs(); ++i) {
348 fbtn = (CustTabButton*)Pack->child(i);
349 CustTabButton *btn = (CustTabButton*)Pack->child(i);
350 if (btn->focus_num() > fbtn->focus_num())
356 Pack->remove(rm_idx);
357 update_pack_offset();
363 if (num_tabs() == 1) {
367 Pack->child(0)->size(0,0);
368 Pack->child(0)->hide();
369 resize(0,0,
window()->w(),ctab_h);
370 Wizard->resize(0,ctab_h,Wizard->w(),
window()->h()-ctab_h);
376int CustTabs::get_btn_idx(
UI *ui)
378 for (
int i = 0; i < num_tabs(); ++i) {
379 CustTabButton *btn = (CustTabButton*)Pack->child(i);
390void CustTabs::update_pack_offset()
395 int act_idx = get_btn_idx((
UI*)Wizard->value());
396 CustTabButton *cbtn = (CustTabButton*)Pack->child(act_idx);
400 for (
int j=0; j < act_idx; ++j)
401 x_i += Pack->child(j)->w();
402 x_f = x_i + cbtn->w();
404 int scr_x = Scroll->xposition(), scr_y = Scroll->yposition();
405 int px_i = x_i - scr_x;
406 int px_f = px_i + cbtn->w();
407 int pw = Scroll->window()->w() - ctl_w;
408 _MSG(
" scr_x=%d btn_x=%d px_i=%d btn_w=%d px_f=%d pw=%d",
409 Scroll->xposition(),cbtn->x(),px_i,cbtn->w(),px_f,pw);
411 Scroll->scroll_to(x_i, scr_y);
412 }
else if (px_i > pw || (px_i > 0 && px_f > pw)) {
413 Scroll->scroll_to(
MIN(x_i, x_f-pw), scr_y);
416 _MSG(
" >>scr_x=%d btn0_x=%d\n", scr_x, Pack->child(0)->x());
422void CustTabs::switch_tab(CustTabButton *cbtn)
427 UI *old_ui = (
UI*)Wizard->value();
429 if (cbtn && cbtn->ui() != old_ui) {
431 if ((idx = get_btn_idx(old_ui)) != -1) {
432 btn = (CustTabButton*)Pack->child(idx);
447 Wizard->value(cbtn->ui());
451 update_pack_offset();
455 const char *title = (cbtn->ui())->label();
459 increase_focus_counter();
460 cbtn->focus_num(focus_counter);
464void CustTabs::prev_tab()
468 if ((idx = get_btn_idx((
UI*)Wizard->value())) != -1)
469 switch_tab((CustTabButton*)Pack->child(idx>0 ? idx-1 : num_tabs()-1));
472void CustTabs::next_tab()
476 if ((idx = get_btn_idx((
UI*)Wizard->value())) != -1)
477 switch_tab((CustTabButton*)Pack->child((idx+1<num_tabs()) ? idx+1 : 0));
483void CustTabs::set_tab_label(
UI *ui,
const char *label)
486 int idx = get_btn_idx(ui);
490 size_t tab_chars = 15, label_len = strlen(label);
492 if (label_len > tab_chars)
494 snprintf(title, tab_chars + 1,
"%s", label);
495 if (label_len > tab_chars)
496 snprintf(title + tab_chars, 4,
"...");
499 if (strcmp(Pack->child(idx)->label(), title)) {
501 Pack->child(idx)->copy_label(title);
502 Pack->child(idx)->measure_label(w, h);
503 Pack->child(idx)->size(w+14,ctab_h);
504 update_pack_offset();
512static void win_cb (Fl_Widget *w,
void *cb_data) {
513 CustTabs *tabs = (CustTabs*) cb_data;
514 int choice = 1, ntabs = tabs->num_tabs();
516 if (Fl::event_key() == FL_Escape) {
524 "Window contains more than one tab.",
525 "Close",
"Cancel", NULL);
537 for (
int i = 0; i <
a_Bw_num(); ++i) {
539 if (((
UI*)bw->
ui)->contains((Fl_Widget*)v_wid)) {
551 uint32_t xid,
const void *vbw)
555 UI *old_ui = old_bw ?
BW2UI(old_bw) : NULL;
558 if (ww <= 0 || wh <= 0) {
565 win =
new Xembed(xid, ww, wh);
567 win =
new Fl_Window(ww, wh);
569 win =
new Fl_Double_Window(ww, wh);
574 win->resizable(DilloTabs->wizard());
580 if (old_bw == NULL) {
589 win->callback(
win_cb, DilloTabs);
601 win->Fl_Widget::copy_label(str);
603 win->label(copy, copy);
612 _MSG(
" UIcmd_tab_new\n");
615 UI *new_ui = tabs->add_new_tab(old_ui, focus);
642 new_bw->
ui = (
void *)new_ui;
663 CustTabs *tabs = ui->
tabs();
666 _MSG(
"a_UIcmd_close_bw\n");
670 tabs->remove_tab(ui);
671 if (tabs->num_tabs() == 0)
672 delete tabs->window();
687 "More than one open tab or window.",
688 "Quit",
"Cancel", NULL);
702 int len = strcspn(str,
" ");
704 if (len > 0 && str[len] !=
'\0') {
729 char *search_urlstr = NULL;
735 urlstr = search_urlstr;
737 if (urlstr && *urlstr) {
744 if (!ch || ch ==
'.') {
761 dFree(search_urlstr);
771 BW2UI(bw)->focus_main();
774 BW2UI(bw)->focus_location();
792 BW2UI(new_bw)->focus_main();
794 BW2UI(new_bw)->focus_location();
822 bw ?
BW2UI(bw) : NULL, focus);
944 char *name, *free1, *free2, *n1, *n2;
946 free1 = free2 = NULL;
950 path2 = strrchr(
path,
'/');
954 if (strlen(
path) > MaxLen) {
962 if (strlen(query) > MaxLen) {
963 query = free2 =
dStrndup(query, MaxLen);
974 for (n1 = n2 = name; *n1; n1++, n2++) {
978 (n1[0] ==
'%' && n1[1] ==
'2' && n1[2] ==
'0')
997 (dir[strlen(dir)-1] ==
'/')
1009 if (stat(name, &ss) == 0) {
1014 "The file: %s (%d Bytes) already exists. What do we do?",
1015 name, (
int)ss.st_size);
1017 "Abort",
"Continue",
"Rename", NULL);
1035 dFree(SuggestedName);
1045 MSG(
"UIcmd_save: %s\n", name);
1056 SuggestedName =
dStrdup(name);
1089 MSG(
"a_UIcmd_stop()\n");
1128 char *search_url, *l, *u, *c;
1135 for (c = u; *c; c++) {
1143 MSG_WARN(
"search_url ends with '%%'\n"); c--;
break;
1145 MSG_WARN(
"illegal specifier '%%%c' in search_url\n", *c);
1153 search_url = ds->
str;
1165 if ((query =
a_Dialog_input(
"Dillo: Search",
"Search the Web:"))) {
1178 const char *title =
"Dillo: Password";
1179 char *msg =
dStrconcat(
"Password for user \"", user,
"\"", NULL);
1190 UIcmd_save(bw, url,
"Dillo: Save Link as File");
1274 static int post_id = 0;
1283 dstr_url =
dStr_new(
"dpi:/vsource/:");
1287 post_id = (post_id < 9999) ? post_id + 1 : 0;
1288 snprintf(tag, 16,
"_%.4d", post_id);
1310 a_Dialog_msg(
"Dillo: Good HTML!",
"No HTML errors found while parsing!");
1337 hlist =
dNew(
int, n + 1);
1364 *w =
BW2UI(bw)->w();
1365 *h =
BW2UI(bw)->h();
1366 _MSG(
"a_UIcmd_wh: w=%d, h=%d\n", *w, *h);
1419 const mapping_t map[] = {
1433 for (
uint_t i = 0; i <
sizeof(map) /
sizeof(map[0]); i++) {
1434 if (keycmd == map[i].keys_cmd) {
1456 BW2UI(bw)->set_location(text);
1465 BW2UI(bw)->set_page_prog(nbytes, cmd);
1474 BW2UI(bw)->set_img_prog(n_img, t_img, cmd);
1486 BW2UI(bw)->set_bug_prog(n_bug);
1495 const int size = 128;
1498 if (snprintf(title, size,
"Dillo: %s", label ? label :
"") >= size) {
1500 snprintf(title + i, 4,
"...");
1502 BW2UI(bw)->copy_label(title);
1503 BW2UI(bw)->tabs()->set_tab_label(
BW2UI(bw), label ? label :
"");
1520 va_start(argp, format);
1551 BW2UI(bw)->panels_toggle();
1558 int case_sens,
int backward)
1562 switch (l->
search(key, case_sens, backward)) {
1564 a_UIcmd_set_msg(bw, backward?
"Top reached; restarting from the bottom."
1565 :
"Bottom reached; restarting from the top.");
1592 BW2UI(bw)->findbar_toggle(on);
1600 BW2UI(bw)->focus_main();
1609 BW2UI(bw)->focus_location();
void a_Bookmarks_add(BrowserWindow *bw, const DilloUrl *url)
Add the new bookmark through the bookmarks server.
bool_t a_Bw_expecting(BrowserWindow *bw)
void a_Bw_free(BrowserWindow *bw)
Free resources associated to a bw.
BrowserWindow * a_Bw_get(int i)
Return a bw by index.
void a_Bw_stop_clients(BrowserWindow *bw, int flags)
Stop the active clients of this bw's top page.
BrowserWindow * a_Bw_new(void)
Create a new browser window and return it.
static KeysCommand_t getKeyCmd(void)
Look if the just pressed key is bound to a command.
static char * getOldWorkingDir(void)
Return the initial current working directory in a string.
void findbar_toggle(bool add)
Adjust space for the findbar (if necessary) and show or remove it.
void set_render_layout(Fl_Group *nw)
Set 'nw' as the main render area widget.
@ SUCCESS
The next occurrence of the pattern has been found.
@ NOT_FOUND
The patten does not at all occur in the text.
@ RESTART
There is no further occurrence of the pattern, instead, the first occurrence has been selected.
The central class for managing and drawing a widget tree.
void attachView(View *view)
Attach a view to the layout.
FindtextState::Result search(const char *str, bool caseSens, int backwards)
See dw::core::FindtextState::search.
void resetSearch()
See dw::core::FindtextState::resetSearch.
void setBgColor(style::Color *color)
void setBgImage(style::StyleImage *bgImage, style::BackgroundRepeat bgRepeat, style::BackgroundAttachment bgAttachment, style::Length bgPositionX, style::Length bgPositionY)
void copySelection(const char *text)
void scrollTo(HPosition hpos, VPosition vpos, int x, int y, int width, int height)
Scrolls all viewports, so that the region [x, y, width, height] is seen, according to hpos and vpos.
void scroll(ScrollCommand)
void setAnchor(const char *anchor)
Sets the anchor to scroll to.
static Color * create(Layout *layout, int color)
void setBufferedDrawing(bool b)
void setPageOverlap(int overlap)
void setScrollbarPageMode(bool enable)
void setDragScroll(bool enable)
void setScrollStep(int step)
void setScrollbarOnLeft(bool enable)
char * a_Dialog_open_file(const char *title, const char *pattern, const char *fname)
Show the open file dialog.
int a_Dialog_choice(const char *title, const char *msg,...)
Make a question-dialog with a question and alternatives.
void a_Dialog_msg(const char *title, const char *msg)
Display a message in a popup window.
const char * a_Dialog_save_file(const char *title, const char *pattern, const char *fname)
Show the save file dialog.
const char * a_Dialog_passwd(const char *title, const char *msg)
Dialog for password.
void a_Dialog_text_window(const char *title, const char *txt)
Show a new window with the provided text.
const char * a_Dialog_select_file(const char *title, const char *pattern, const char *fname)
Show the select file dialog.
const char * a_Dialog_input(const char *title, const char *msg)
Dialog for one line of Input with a message.
char * dStrconcat(const char *s1,...)
Concatenate a NULL-terminated list of strings.
int dStrAsciiCasecmp(const char *s1, const char *s2)
void dStr_append(Dstr *ds, const char *s)
Append a C string to a Dstr.
char * dStrdup(const char *s)
Dstr * dStr_sized_new(int sz)
Create a new string with a given size.
int dStrnAsciiCasecmp(const char *s1, const char *s2, size_t n)
int dList_length(Dlist *lp)
For completing the ADT.
void * dList_nth_data(Dlist *lp, int n0)
Return the nth data item, NULL when not found or 'n0' is out of range.
void dStr_free(Dstr *ds, int all)
Free a dillo string.
void dStr_append_c(Dstr *ds, int c)
Append one character.
char * dStrndup(const char *s, size_t sz)
void dStr_sprintf(Dstr *ds, const char *format,...)
Printf-like function.
Dstr * dStr_new(const char *s)
Create a new string.
void dStr_vsprintf(Dstr *ds, const char *format, va_list argp)
vsprintf-like function.
#define dNew(type, count)
static Fl_Window * window
static FltkPlatform * platform
static FltkViewport * viewport
const DilloUrl * a_History_get_url(int idx)
Return the DilloUrl field (by index)
int a_Misc_parse_search_url(char *source, char **label, char **urlstr)
Parse dillorc's search_url string ([<label> ]<url>) Return value: -1 on error, 0 on success (and labe...
void a_Misc_parse_content_type(const char *type, char **major, char **minor, char **charset)
Parse Content-Type string, e.g., "text/html; charset=utf-8".
@ BACKGROUND_ATTACHMENT_SCROLL
Length createPerLength(double v)
Returns a percentage, v is relative to 1, not to 100.
The core of Dw is defined in this namespace.
This namespace contains FLTK implementations of Dw interfaces.
int a_Nav_stack_ptr(BrowserWindow *bw)
void a_Nav_redirection0(BrowserWindow *bw, const DilloUrl *new_url)
void a_Nav_forw(BrowserWindow *bw)
const char * a_Nav_get_content_type(const DilloUrl *url)
void a_Nav_cancel_expect(BrowserWindow *bw)
void a_Nav_jump(BrowserWindow *bw, int offset, int new_bw)
void a_Nav_back(BrowserWindow *bw)
void a_Nav_reload(BrowserWindow *bw)
void a_Nav_repush(BrowserWindow *bw)
void a_Nav_unref_buf(const DilloUrl *Url)
int a_Nav_stack_size(BrowserWindow *bw)
void a_Nav_set_vsource_url(const DilloUrl *Url)
void a_Nav_save_url(BrowserWindow *bw, const DilloUrl *url, const char *filename)
int a_Nav_get_buf(const DilloUrl *Url, char **PBuf, int *BufSize)
void a_Nav_push(BrowserWindow *bw, const DilloUrl *url, const DilloUrl *requester)
DilloPrefs prefs
Global Data.
#define PREFS_UI_TAB_ACTIVE_BG_COLOR
#define PREFS_UI_TAB_ACTIVE_FG_COLOR
#define PREFS_UI_TAB_FG_COLOR
#define PREFS_UI_TAB_BG_COLOR
Contains the specific data for a single window.
Dlist * ImageClients
Image Keys for all active connections in the window.
Dlist * RootClients
A list of active cache clients in the window (The primary Key)
void * render_layout
All the rendering is done by this.
void * ui
Pointer to the UI object this bw belongs to.
int num_page_bugs
HTML-bugs detected at parse time.
bool_t middle_click_drags_page
bool_t right_click_closes_tab
bool_t scrollbar_page_mode
int32_t scroll_page_overlap
bool_t scroll_switches_tabs
bool_t scroll_switches_tabs_reverse
void a_Timeout_add(float t, TimeoutCb_t cb, void *cbdata)
Hook a one-time timeout function 'cb' after 't' seconds with 'cbdata" as its data.
void a_UIcmd_tools(void *vbw, int x, int y)
void a_UIcmd_link_popup(void *vbw, const DilloUrl *url)
const char * a_UIcmd_get_passwd(const char *user)
static void UIcmd_open_url_nbw(BrowserWindow *new_bw, const DilloUrl *url)
static BrowserWindow * UIcmd_tab_new(CustTabs *tabs, UI *old_ui, int focus)
void a_UIcmd_set_bug_prog(BrowserWindow *bw, int n_bug)
void a_UIcmd_set_scroll_xy(BrowserWindow *bw, int x, int y)
void a_UIcmd_page_popup(void *vbw, bool_t has_bugs, void *v_cssUrls)
void a_UIcmd_bugmeter_popup(void *vbw)
void a_UIcmd_set_msg(BrowserWindow *bw, const char *format,...)
static char * UIcmd_find_search_str(const char *str)
void a_UIcmd_home(void *vbw)
void a_UIcmd_copy_urlstr(BrowserWindow *bw, const char *urlstr)
void a_UIcmd_form_popup(void *vbw, const DilloUrl *url, void *vform, bool_t showing_hiddens)
void a_UIcmd_close_bw(void *vbw)
static char * UIcmd_make_search_str(const char *str)
void a_UIcmd_image_popup(void *vbw, const DilloUrl *url, bool_t loaded_img, DilloUrl *page_url, DilloUrl *link_url)
int * a_UIcmd_get_history(BrowserWindow *bw, int direction)
static void win_cb(Fl_Widget *w, void *cb_data)
void a_UIcmd_open_file(void *vbw)
BrowserWindow * a_UIcmd_browser_window_new(int ww, int wh, uint32_t xid, const void *vbw)
void a_UIcmd_focus_location(void *vbw)
void a_UIcmd_zoom_reset(void *vbw)
void a_UIcmd_zoom_in(void *vbw)
void a_UIcmd_zoom_out(void *vbw)
void a_UIcmd_set_page_title(BrowserWindow *bw, const char *label)
void a_UIcmd_focus_main_area(BrowserWindow *bw)
void a_UIcmd_findtext_search(BrowserWindow *bw, const char *key, int case_sens, int backward)
void a_UIcmd_reload(void *vbw)
static void tab_btn_cb(Fl_Widget *w, void *cb_data)
Callback for mouse click.
#define DEFAULT_TAB_LABEL
BrowserWindow * a_UIcmd_get_bw_by_widget(void *v_wid)
void a_UIcmd_file_popup(void *vbw, void *v_wid)
void a_UIcmd_open_url_nw(BrowserWindow *bw, const DilloUrl *url)
static void close_tab_btn_cb(Fl_Widget *w, void *cb_data)
Callback for the close-tab button.
void a_UIcmd_view_page_source(BrowserWindow *bw, const DilloUrl *url)
void a_UIcmd_book(void *vbw)
void a_UIcmd_search_dialog(void *vbw)
void a_UIcmd_view_page_bugs(void *vbw)
void a_UIcmd_nav_jump(BrowserWindow *bw, int offset, int new_bw)
static char * UIcmd_make_save_filename(const DilloUrl *url)
void a_UIcmd_findbar_toggle(BrowserWindow *bw, int on)
static int btn_cmp(const void *p1, const void *p2)
void a_UIcmd_get_wh(BrowserWindow *bw, int *w, int *h)
void a_UIcmd_open_urlstr(void *vbw, const char *urlstr)
void a_UIcmd_set_buttons_sens(BrowserWindow *bw)
void a_UIcmd_panels_toggle(BrowserWindow *bw)
const char * a_UIcmd_select_file()
void a_UIcmd_forw_popup(void *vbw, int x, int y)
void a_UIcmd_save(void *vbw)
void a_UIcmd_back(void *vbw)
void a_UIcmd_get_scroll_xy(BrowserWindow *bw, int *x, int *y)
void a_UIcmd_forw(void *vbw)
void a_UIcmd_save_link(BrowserWindow *bw, const DilloUrl *url)
static void UIcmd_save(BrowserWindow *bw, const DilloUrl *url, const char *title)
void a_UIcmd_repush(void *vbw)
void a_UIcmd_back_popup(void *vbw, int x, int y)
char * a_UIcmd_get_location_text(BrowserWindow *bw)
void a_UIcmd_close_all_bw(void *)
static const char * save_dir
void a_UIcmd_add_bookmark(BrowserWindow *bw, const DilloUrl *url)
void a_UIcmd_open_url(BrowserWindow *bw, const DilloUrl *url)
void a_UIcmd_set_page_prog(BrowserWindow *bw, size_t nbytes, int cmd)
void a_UIcmd_stop(void *vbw)
void a_UIcmd_findtext_reset(BrowserWindow *bw)
void a_UIcmd_scroll(BrowserWindow *bw, int icmd)
static void UIcmd_set_window_labels(Fl_Window *win, const char *str)
void a_UIcmd_set_scroll_by_fragment(BrowserWindow *bw, const char *f)
void a_UIcmd_set_img_prog(BrowserWindow *bw, int n_img, int t_img, int cmd)
static int UIcmd_save_file_check(const char *name)
void a_UIcmd_redirection0(void *vbw, const DilloUrl *url)
void a_UIcmd_set_location_text(void *vbw, const char *text)
void a_UIcmd_open_url_nt(void *vbw, const DilloUrl *url, int focus)
char * a_Url_string_strip_delimiters(const char *str)
RFC-3986 suggests this stripping when "importing" URLs from other media.
char * a_Url_encode_hex_str(const char *str)
Urlencode 'str'.
void a_Url_free(DilloUrl *url)
Free a DilloUrl.
DilloUrl * a_Url_new(const char *url_str, const char *base_url)
Transform (and resolve) an URL string into the respective DilloURL.
uint_t a_Utf8_end_of_char(const char *str, uint_t i)
Return index of the last byte of the UTF-8-encoded character that str + i points to or into.