blob: 1959a71822742badce7e575897b89ccc9e8d91ad (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
|
# HtmlViewer class definition
# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
# the Free Software Foundation; either version 2 of the License, or (at
# your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
# -----------------------------------------------------------------------------
# NAME:
# class HtmlViewer
#
# DESC:
# This class implements a simple HTML browser. It has both pulldown
# menus and buttons for navigating. It uses the scrolledhtml iwidget
# to do its rendering.
#
# NOTES:
# Currently used as a help window.
#
# -----------------------------------------------------------------------------
class HtmlViewer {
inherit EmbeddedWin
public {
variable topics {
{index index.html}
{"Attach Dialog" attach.html}
{"Breakpoint Window" breakpoint.html}
{"Console Window" console.html }
{"Function Browser" browser.html }
{"Locals Window" locals.html }
{"Memory Window" memory.html}
{"Register Window" register.html}
{"Source Window" source.html}
{"Stack Window" stack.html}
{"Target Window" target.html }
{"Thread Window" thread.html }
{"Watch Window" watch.html}
}
variable file "index.html"
method back {}
method forward {}
method link {link}
method load {link}
method close {}
method constructor {args}
proc open_help {file}
}
private {
variable _html
variable _links
variable _m
variable _f
method _enable {on args}
method _buildwin {}
}
}
# -----------------------------------------------------------------------------
# NAME:
# class PageStack
#
# DESC:
# Implements a stack-like class for saving and recalling items
# like pages in a help browser. It differs from a traditional
# stack only by the 'back' and 'next' methods which move up and
# down the stack without disturbing it, unlike 'push' and 'pop'.
#
# NOTES:
# Currently used by the HtmlViewer class.
#
# -----------------------------------------------------------------------------
class PageStack {
private {
variable _ptr -1
variable _max -1
variable _stack
}
public {
method push {val}
method back {}
method next {}
method more {}
method less {}
method current {}
}
}
|