User Guide

Lua Support in Wireshark
169
11.7.2.9.2. Returns
The TextWindow object.
11.7.2.9.3. Errors
Cannot be called for something not a TextWindow
11.7.3. Non Method Functions
11.7.3.1. gui_enabled()
Checks whether the GUI facility is enabled.
11.7.3.1.1. Returns
A boolean: true if it is enabled, false if it isn't.
11.7.3.2. register_menu(name, action, [group])
Register a menu item in one of the main menus.
11.7.3.2.1. Arguments
name The name of the menu item. The submenus are to be separated by '/'s. (string)
action The function to be called when the menu item is invoked. (function taking no
arguments and returning nothing)
group (optional) The menu group into which the menu item is to be
inserted. If omitted, defaults to MENU_STAT_GENERIC. One
of MENU_STAT_UNSORTED (Statistics), MENU_STAT_GENERIC
(Statistics, first section), MENU_STAT_CONVERSATION (Statistics/
Conversation List), MENU_STAT_ENDPOINT (Statistics/Endpoint
List), MENU_STAT_RESPONSE (Statistics/Service Response Time),
MENU_STAT_TELEPHONY (Telephony), MENU_ANALYZE (Analyze),
MENU_ANALYZE_CONVERSATION (Analyze/Conversation Filter),
MENU_TOOLS_UNSORTED (Tools). (number)
11.7.3.3. new_dialog(title, action, ...)
Pops up a new dialog
11.7.3.3.1. Arguments
title Title of the dialog's window.
action Action to be performed when OKd.
... A series of strings to be used as labels of the dialog's fields
11.7.3.3.2. Errors
At least one field required