From a9ab6abafd54c30086178eb6743d5e9ef5f439cf Mon Sep 17 00:00:00 2001 From: Florian Bruhin Date: Sun, 15 May 2016 11:09:16 +0200 Subject: [PATCH] Document {url} and {url:pretty} for :set-cmd-text --- doc/help/commands.asciidoc | 2 ++ qutebrowser/mainwindow/statusbar/command.py | 3 +++ 2 files changed, 5 insertions(+) diff --git a/doc/help/commands.asciidoc b/doc/help/commands.asciidoc index 97896ae64..e9cb4571c 100644 --- a/doc/help/commands.asciidoc +++ b/doc/help/commands.asciidoc @@ -650,6 +650,8 @@ Syntax: +:set-cmd-text [*--space*] [*--append*] 'text'+ Preset the statusbar to some text. +You can use the `{url}` and `{url:pretty}` variables here which will get replaced by the encoded/decoded URL. + ==== positional arguments * +'text'+: The commandline to set. diff --git a/qutebrowser/mainwindow/statusbar/command.py b/qutebrowser/mainwindow/statusbar/command.py index a8cc0c16c..e00e4b2b4 100644 --- a/qutebrowser/mainwindow/statusbar/command.py +++ b/qutebrowser/mainwindow/statusbar/command.py @@ -95,6 +95,9 @@ class Command(misc.MinimalLineEditMixin, misc.CommandLineEdit): def set_cmd_text_command(self, text, space=False, append=False): """Preset the statusbar to some text. + You can use the `{url}` and `{url:pretty}` variables here which will get + replaced by the encoded/decoded URL. + // Wrapper for set_cmd_text to check the arguments and allow multiple