GNU Octave
3.8.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
|
Hotspot type created by UrlFilter instances. More...
#include "Filter.h"
Public Types | |
enum | Type { NotSpecified, Link, Marker } |
Public Member Functions | |
HotSpot (int startLine, int startColumn, int endLine, int endColumn) | |
Constructs a new hotspot which covers the area from (startLine ,startColumn ) to (endLine ,endColumn ) in a block of text. | |
virtual | ~HotSpot () |
virtual QList< QAction * > | actions () |
Returns a list of actions associated with the hotspot which can be used in a menu or toolbar. | |
virtual void | activate (QObject *object=0) |
Open a web browser at the current URL. | |
QStringList | capturedTexts () const |
Returns the texts found by the filter when matching the filter's regular expression. | |
int | endColumn () const |
Returns the column on endLine() where the hotspot area ends. | |
int | endLine () const |
Returns the line where the hotspot area ends. | |
void | setCapturedTexts (const QStringList &texts) |
Sets the captured texts associated with this hotspot. | |
int | startColumn () const |
Returns the column on startLine() where the hotspot area starts. | |
int | startLine () const |
Returns the line when the hotspot area starts. | |
virtual QString | tooltip () const |
Returns the text of a tooltip to be shown when the mouse moves over the hotspot, or an empty string if there is no tooltip associated with this hotspot. | |
Type | type () const |
Returns the type of the hotspot. |
Protected Member Functions | |
void | setType (Type type) |
Sets the type of a hotspot. |
Private Types | |
enum | UrlType { StandardUrl, Email, Unknown } |
Private Member Functions | |
UrlType | urlType () const |
Private Attributes | |
FilterObject * | _urlObject |
Hotspot type created by UrlFilter instances.
The activate() method opens a web browser at the given URL when called.
|
inherited |
|
private |
Constructs a new hotspot which covers the area from (startLine
,startColumn
) to (endLine
,endColumn
) in a block of text.
Reimplemented from RegExpFilter::HotSpot.
Definition at line 422 of file Filter.cpp.
References Filter::HotSpot::Link, and Filter::HotSpot::setType().
|
virtual |
Reimplemented from Filter::HotSpot.
Definition at line 510 of file Filter.cpp.
|
virtual |
Returns a list of actions associated with the hotspot which can be used in a menu or toolbar.
Reimplemented from Filter::HotSpot.
Definition at line 518 of file Filter.cpp.
Open a web browser at the current URL.
The url itself can be determined using the capturedTexts() method.
Reimplemented from RegExpFilter::HotSpot.
Definition at line 453 of file Filter.cpp.
|
inherited |
Returns the texts found by the filter when matching the filter's regular expression.
Definition at line 346 of file Filter.cpp.
|
inherited |
Returns the column on endLine() where the hotspot area ends.
Definition at line 315 of file Filter.cpp.
Referenced by Filter::hotSpotAt(), TerminalView::hotSpotRegion(), and TerminalView::paintFilters().
|
inherited |
Returns the line where the hotspot area ends.
Definition at line 307 of file Filter.cpp.
Referenced by Filter::hotSpotAt(), TerminalView::hotSpotRegion(), and TerminalView::paintFilters().
|
inherited |
Sets the captured texts associated with this hotspot.
Definition at line 342 of file Filter.cpp.
Sets the type of a hotspot.
This should only be set once
Definition at line 323 of file Filter.cpp.
Referenced by RegExpFilter::HotSpot::HotSpot(), and HotSpot().
|
inherited |
Returns the column on startLine() where the hotspot area starts.
Definition at line 311 of file Filter.cpp.
Referenced by Filter::hotSpotAt(), TerminalView::hotSpotRegion(), and TerminalView::paintFilters().
|
inherited |
Returns the line when the hotspot area starts.
Definition at line 303 of file Filter.cpp.
Referenced by Filter::hotSpotAt(), TerminalView::hotSpotRegion(), and TerminalView::paintFilters().
|
virtual |
Returns the text of a tooltip to be shown when the mouse moves over the hotspot, or an empty string if there is no tooltip associated with this hotspot.
The default implementation returns an empty string.
Reimplemented from Filter::HotSpot.
Definition at line 428 of file Filter.cpp.
|
inherited |
Returns the type of the hotspot.
This is usually used as a hint for views on how to represent the hotspot graphically. eg. Link hotspots are typically underlined when the user mouses over them
Definition at line 319 of file Filter.cpp.
Referenced by TerminalView::paintFilters().
|
private |
Definition at line 441 of file Filter.cpp.
References UrlFilter::EmailAddressRegExp, and UrlFilter::FullUrlRegExp.
|
private |