First time here? Check out the FAQ!
THIS IS A TEST INSTANCE. Feel free to ask and answer questions, but take care to avoid triggering too many notifications.
0

Adding file path to title bar

I often analyze multiple traces at the same time which often have the same name. It would be helpful if I could set the windows GUI title bar to show the full path and name of the trace file.

I see under Preferences > Advanced the gui.window_title and gui_prepend_window title options. Is there a certain value that might represent the full path to the file? I know I could manually enter the path value every time I open a trace but I'm hoping there is a value I could set that would automatically pick up the path every time I open a new trace file.

Betsy0129's avatar
3
Betsy0129
asked 2023-06-27 17:59:06 +0000
edit flag offensive 0 remove flag close merge delete

Comments

I see under Preferences > Advanced the gui.window_title and gui_prepend_window title options.

You'll also see "Window title" and "Prepend window title" options under Preferences > Appearance - no need to dive into the advanced options.

Guy Harris's avatar Guy Harris (2023-06-29 05:37:00 +0000) edit
add a comment see more comments

1 Answer

0

From the source code:

register_string_like_preference(gui_module, "window_title", "Custom window title",
    "Custom window title to be appended to the existing title\n"
    "%F = file path of the capture file\n"
    "%P = profile name\n"
    "%S = a conditional separator (\" - \") that only shows when surrounded by variables with values or static text\n"
    "%V = version info",
    &prefs.gui_window_title, PREF_STRING, NULL, TRUE);
SYN-bit's avatar
18.5k
SYN-bit
answered 2023-06-27 18:06:42 +0000
edit flag offensive 0 remove flag delete link

Comments

What version of Wireshark are you running?
If not fixed in the latest version, you could test with a development build.
3453: Qt: Edit->Preferences resets titlebar and statusBar to defaults

Chuckc's avatar Chuckc (2023-06-27 18:19:13 +0000) edit

Adding %F to the gui.prepend_window_title was exactly what I was looking for. Thank you.

Betsy0129's avatar Betsy0129 (2023-06-27 18:47:33 +0000) edit

That's... not the place where this should be documented.

Section 11.5. "Preferences" of the Wireshark User's Guide needs to be greatly expanded - and updated, given that, among other things, the "Window title" and "Prepend window title" preferences date back at least to Wireshark 3.6, but the screenshot of the Appearance page doesn't show it.

Guy Harris's avatar Guy Harris (2023-06-29 06:14:17 +0000) edit

Bug #19176 filed on the deficient "Preferences" section.

Guy Harris's avatar Guy Harris (2023-06-29 06:49:14 +0000) edit
add a comment see more comments

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account. This space is reserved only for answers. If you would like to engage in a discussion, please instead post a comment under the question or an answer that you would like to discuss.

Add Answer