You are not logged in.
Hi,
dwb doesn't pick up my $http_proxy and $no_proxy variables. It allows you to specify a proxy in the settings, but there is no ignore list. When toggling the proxy with Ctrl+p, the proxy defined in the settings always remains active so I cannot turn it off without removing the "proxy-url" entry in the settings.
I'm using the latest stable version.
Many thanks
PGP key: F40D2072
Key fingerprint: 8742 F753 5E7B 394A 1B04 8163 332C 9C40 F40D 2072
Offline
Hi,
dwb doesn't pick up my $http_proxy and $no_proxy variables. It allows you to specify a proxy in the settings, but there is no ignore list. When toggling the proxy with Ctrl+p, the proxy defined in the settings always remains active so I cannot turn it off without removing the "proxy-url" entry in the settings.
I'm using the latest stable version.
Many thanks
For me it does pick up the $http_proxy variable, but it will only have effect if the settings "proxy" is set to true.
Ctrl+p works for me too, except that the settings page (dwb://settings) doesn't reflect the new value, probably due to it being created from $XDG_CONFIG_CONFIG/dwb/settings, and not the settings in memory.
I tested this by using a off-site proxy, visiting and reloading http://whatismyip.org while toggling the proxy false/true with Ctrl-P a few times to make sure my IP-address was different.
Offline
OK I see. I'll try not setting the proxy-url when I'm back at work tomorrow and see if it picks up my variables.
I would like to adjust the size/padding of the bars without affecting the font size. Is that currently possible?
Many thanks
PGP key: F40D2072
Key fingerprint: 8742 F753 5E7B 394A 1B04 8163 332C 9C40 F40D 2072
Offline
I'll have a look into the proxy thing. There was already a feature request about padding in the statusbar, i closed the ticket with 'won't fix' and sent the requester a patch, maybe i'll apply the patch to the main branch.
Offline
Just found the patch; it's perfect! Cheers.
PGP key: F40D2072
Key fingerprint: 8742 F753 5E7B 394A 1B04 8163 332C 9C40 F40D 2072
Offline
Tags for bookmarks are on my todo list but i don't know when they will be added. But you can have more than 26 quickmarks, quickmarks can also be complete words. If you want to create a quickmark for NY Times you can add a quickmark with m nyt and open it with b nyt, it is also possible to tabcomplete quickmarks.
Nice, I didn't know that yet, but it works like a charm. Thanks for making quickmarks much more usable!
Offline
After a couple weeks of using dwb, and comparing it with luakit/uzbl/pentadactyl, I think I'm in love! I've changed a lot of the keybindings to things that make a bit more sense to me, and added a few custom ones too. I love how easy it is to configure everything in dwb.
I just have two quick questions, and one comment.
(1) Is it possible to use the backspace key in a keybinding? I'd like to bind the new "toggle_tab" command to ctrl-backspace, but "Control @Backspace@" doesn't work.
(2) Is it possible to load a previously saved session from within an instance of dwb, e.g., by issuing something like ":load_session <session-name>"? And relatedly, is it possible to delete a saved session either from within dwb or from the command line, without having to manually delete the relevant lines from the session file?
(3) I noticed in one of the commit messages that there is a new "sanitize" command--very useful! However, it's not yet in the man pages or in dwb:keys. It'd be useful to be able to bind it to something.
Thanks!
Brian
P.S. For those interested, here is a custom keybindings you might find useful. It lets you press "cc" to totally clear all tabs, leaving you with one blank tab with no history (for that tab). It's useful when you want to start fresh (or quickly hide tabs from someone approaching your desk...), but you can still undo the closed tabs if you need to.
cc:tab_new;;only;;clear_tab
Offline
(1) Is it possible to use the backspace key in a keybinding? I'd like to bind the new "toggle_tab" command to ctrl-backspace, but "Control @Backspace@" doesn't work.
(2) Is it possible to load a previously saved session from within an instance of dwb, e.g., by issuing something like ":load_session <session-name>"? And relatedly, is it possible to delete a saved session either from within dwb or from the command line, without having to manually delete the relevant lines from the session file?
(3) I noticed in one of the commit messages that there is a new "sanitize" command--very useful! However, it's not yet in the man pages or in dwb:keys. It'd be useful to be able to bind it to something.
1. This is now possible in with the latest revision, but it is @BackSpace@ not @Backspace@.
2. This is currently not possible, but i consider adding such a command.
3. Yeah, i know that it is not mentioned in the man page, it is not in the man page because i don't know if i keep sanitize in the current form. It doesn't appear in dwb:keys because sanitize can also take an argument, e.g. :sanitize history will only clear history and :sanitize cookies will only clear cookies. There are several commands that are not listed in dwb:keys.
Offline
I'm having trouble getting JS userscripts to work (I've tried both custom keys and a #!javascript userscript) - any hints would be great.
The custom key I'm trying is:
MM:open javascript:void((function(){var%20e=document.createElement('script');e.setAttribute('type','text/javascript');e.setAttribute('charset','UTF-8');e.setAttribute('src','http://mlkshk.com/static/straw/compact.js?r='+Math.random()*99999999);document.body.appendChild(e)})());
The userscript is pretty much the same except it's in the following format:
bind("gM", function(){
tabs.current.inject(blahblah);
}, "mlkshk");
where "blahblah" is a non-encoded javascript snippet.
The userscript isn't recognized at all (i.e., "no userscripts available" when pressing "eu") and nothing "appears" to happen when using the custom key version. Is there some way of getting debugging output from dwb when fiddling with this sort of thing?
Thanks.
[edit]
I've just realized that the link in the snippet above loads more JS - that's clearly the issue and I'll play with that JS a bit.
Debugging output would still be handy
Last edited by syngin (2012-07-11 07:48:13)
Offline
You have to decode the javascript snippet, i.e. %20 must be replace with ' '. The shortcut 'eu' is only for userscripts that doesn't use the javascript api, it is the shortcut for 'execute userscript' but scripts that use the javascript api cannot be executed, they are only parsed on startup. Using the javascript api you could try
#!javascript
var myScript = "var e=document.createElement('script');e.setAttribute('type','text/javascript');e.setAttribute('charset','UTF-8');e.setAttribute('src','http://mlkshk.com/static/straw/compact.js?r='+Math.random()*99999999);document.body.appendChild(e);");
bind("gM", function(){
tabs.current.inject(decodeURI(my);
}, "mlkshk");
For javascript snippets you can use the web inspector, if there is an error in a script that use the javascript api dwb will print the error to stderr.
Offline
Thanks portix; that worked a treat. I've included the slightly mended script you posted just in case any one else here uses mlkshk. And thanks for a great browser UI.
#!javascript
var myScript = "var e=document.createElement('script');e.setAttribute('type','text/javascript');e.setAttribute('charset','UTF-8');e.setAttribute('src','http://mlkshk.com/static/straw/compact.js?r='+Math.random()*99999999);document.body.appendChild(e);";
bind("gM", function(){
tabs.current.inject(decodeURI(myScript));
}, "mlkshk");
Offline
There was an mistake in my post, you don't need decodeURI if %20 is already replaced with a space.
Offline
There was an mistake in my post, you don't need decodeURI if %20 is already replaced with a space.
I'll admit, I was a little confused about that
Offline
Ocassionally when using dwb, the command bar stops accepting input correctly. i.e., if I press "O" (tabopen), there's no blinking cursor in the command bar and the next letter I type gets sent as a command. A restart solves it, but obviously not ideal. Any ideas?
Offline
Offline
Why, yes I am. The only reason is that when I compile the GTK2 version, I get huge black borders around widgets.
Offline
The missing input focus is a gtk3 bug, i think it only appears in non reparenting window managers. I implemented some testcases a few months ago and it is also reproducible in a simple textbox inside a window.
Offline
Righto; well, that's a pooper. Guess I'll have a crack at sussing out why GTK2 is a bit borky on this system. Thanks for the heads-up.
Offline
The latest dwb-hg pull breaks keybinding completion. I have auto-completion checked to true, but when I press, say, "g", I don't see a list of keybindings.
Before updating, I would press "g" and see things like: "gg scroll_top | gt buffers | ...". I could then tab through the possible keybindings.
Any idea what happened?
P.S. I hadn't updated dwb-hg in about a week, so it may not be the absolute latest version that is responsible.
Last edited by brianb (2012-07-19 14:02:14)
Offline
The latest dwb-hg pull breaks keybinding completion. I have auto-completion checked to true, but when I press, say, "g", I don't see a list of keybindings.
Before updating, I would press "g" and see things like: "gg scroll_top | gt buffers | ...". I could then tab through the possible keybindings.
Any idea what happened?
P.S. I hadn't updated dwb-hg in about a week, so it may not be the absolute latest version that is responsible.
The new statusbar-padding setting broke the shorcut-completion, this is now fixed in tip.
Offline
The new statusbar-padding setting broke the shorcut-completion, this is now fixed in tip.
Works again -- thanks!
Just a couple of other, minor issues.
1) pressing a normal letter like "g" shows the letter "g" at the far left of the status bar (plus the completions), but pressing ";" does not show ";" (it shows only the completions).
2) pressing "Control e" to open my editor produces a stray "e" in the status bar, which is not cleared even after quitting my editor. (Curiously, the "e" doesn't actually DO anything: no completions are visible, and pressing a key like "j" scrolls down instead of doing nothing; whereas pressing "e" normally shows completions, and followed by "j" does nothing since "ej" is not a keybinding.)
Offline
Righto; well, that's a pooper. Guess I'll have a crack at sussing out why GTK2 is a bit borky on this system. Thanks for the heads-up.
The GTK2 build seems to need Composite extension enabled for some reason.
@portix, how are the download tabs handled?
I get some flickering on monsterwm when there are some downloads going on. Might help me to figure it out
Offline
Is there a way for a (non-javascript) userscript to open a prompt in dwb and get some input from the user?
Specifically, I'm trying to mimic the behavior of the built-in command 'open', which will either take a URL via an argument, or if there is no argument, will prompt for one.
Thanks for any help on that!
Offline
Hi.
Is there a way to change background color of about:blank?
Thanks.
Offline
how are the download tabs handled?
I get some flickering on monsterwm when there are some downloads going on. Might help me to figure it out
The download labels are simple gtklabels, the text on the label is updated when the download progress changes.
Is there a way for a (non-javascript) userscript to open a prompt in dwb and get some input from the user?
Specifically, I'm trying to mimic the behavior of the built-in command 'open', which will either take a URL via an argument, or if there is no argument, will prompt for one.
Why don't you just use o? I don't know how this could be useful but here is a bash script:
#!/bin/bash
if [ "$DWB_ARGUMENT" ]; then
echo "open $DWB_ARGUMENT" > "$DWB_FIFO"
else
echo "open" > "$DWB_FIFO"
fi
There is no builtin possibility to change the color of about:blank. You can change the background color with a custom user stylesheet by setting the the body's background color, or with the following userscript
#!javascript
signals.connect("documentLoaded", function (wv) {
if (wv.uri == "about:blank") {
wv.inject("document.body.style.background = '#000';");
}
});
Offline