Debian Codegraph @

sourcecodepane.h

raw symbols SCIP
1 // File: sourcecodepane.hcxx . . $ `<file>/sourcecodepane.h`/
2 /*
3 Pep8-1 is a virtual machine for writing machine language and assembly
4 language programs.
5
6 Copyright (C) 2009 J. Stanley Warford, Pepperdine University
7
8 This program is free software: you can redistribute it and/or modify
9 it under the terms of the GNU General Public License as published by
10 the Free Software Foundation, either version 3 of the License, or
11 (at your option) any later version.
12
13 This program is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 GNU General Public License for more details.
17
18 You should have received a copy of the GNU General Public License
19 along with this program. If not, see <http://www.gnu.org/licenses/>.
20 */
21
22 #ifndef SOURCECODEPANE_H
23 #define SOURCECODEPANE_Hcxx . . $ `sourcecodepane.h:23:9`!
24
25 #include <QWidget>
26 #include <QString>
27 #include <QList>
28 #include "asm.h"cxx . . $ `<file>/asm.h`/ // For Code in QList<Code *> codeList;
29 #include "pephighlighter.h"cxx . . $ `<file>/pephighlighter.h`/ // For syntax highlighting
30 #include "enu.h"cxx . . $ `<file>/enu.h`/
31
32 namespace Uicxx . . $ Ui/ {
33 class SourceCodePanecxx . . $ Ui/SourceCodePane#;
34 }
35
36 class SourceCodePanecxx . . $ SourceCodePane# : public QWidgetcxx . . $ QWidget# {
37 Q_OBJECTcxx . . $ SourceCodePane#QPrivateSignal#
38 Q_DISABLE_COPYcxx . . $ SourceCodePane#(SourceCodePane)
39 public:
40 explicit SourceCodePanecxx . . $ SourceCodePane#SourceCodePane(108f35f7aa7f3cf9).(QWidgetcxx . . $ QWidget# *parent = 0);
41 virtual ~cxx . . $ SourceCodePane#`~SourceCodePane`(ced63f7c635d850d).SourceCodePanecxx . . $ SourceCodePane#();
42
43 bool assemblecxx . . $ SourceCodePane#assemble(c9857a73d68e59ba).();
44 // Pre: The source code pane contains a Pep/8 source program.
45 // Post: If the program assembles correctly, true is returned, and codeList is populated
46 // with the code objects. Otherwise false is returned and codeList is partially populated.
47 // Post: Pep::symbolTable is populated with values not adjusted for .BURN.
48 // Post: Pep::byteCount is the byte count for the object code not adjusted for .BURN.
49 // Post: Pep::burnCount is the number of .BURN instructions encountered in the source program.
50
51 QListcxx . . $ QList#<int> getObjectCodecxx . . $ SourceCodePane#getObjectCode(9be6d6d0db5cf9a9).();
52 // Pre: codeList is populated with code from a complete correct Pep/8 source program.
53 // Post: objectCode is populated with the object code, one byte per entry, and returned.
54
55 QStringListcxx . . $ QStringList# getAssemblerListingListcxx . . $ SourceCodePane#getAssemblerListingList(669a05bc42dd57cc).();
56 // Pre: codeList is populated with code from a complete correct Pep/8 source program.
57 // Post: assemlberListingList is populated with the assembler listing.
58 // Post: listingTraceList is populated with the object code.
59 // Post: hasCheckBox is populated with the checkBox list that specifies whether a trace line can have a break point.
60 // Post: assemblerListingList is returned.
61
62 QStringListcxx . . $ QStringList# getListingTraceListcxx . . $ SourceCodePane#getListingTraceList(669a05bc42dd57cc).();
63 // Pre: listingTraceList is populated.
64 // Post: ListingTraceList is returned.
65
66 QListcxx . . $ QList#<bool> getHasCheckBoxcxx . . $ SourceCodePane#getHasCheckBox(901f99b7efa3626e).();
67 // Pre: hasCheckBox is populated.
68 // Post: hasCheckBox is returned.
69
70 void adjustCodeListcxx . . $ SourceCodePane#adjustCodeList(d4f767463ce0a6b3).(int addressDelta);
71 // Pre: codeList is populated with code from a complete correct Pep/8 source program.
72 // Post: The memAddress field of each code object is incremented by addressDelta.
73
74 void installOScxx . . $ SourceCodePane#installOS(49f6e7a06ebc5aa8).();
75 // Pre: objectCode is populated with code from a complete correct Pep/8 OS source program.
76 // Post: objectCode is loaded into OS rom of Pep::Mem.
77
78 bool installDefaultOscxx . . $ SourceCodePane#installDefaultOs(c9857a73d68e59ba).();
79 // Post: the pep/8 operating system is installed into memory, and true is returned
80 // If assembly fails, false is returned
81 // This function should only be called on program startup once
82
83 void removeErrorMessagescxx . . $ SourceCodePane#removeErrorMessages(49f6e7a06ebc5aa8).();
84 // Post: Searces for the string ";ERROR: " on each line and removes the end of the line.
85 // Post: Searces for the string ";WARNING: " on each line and removes the end of the line.
86
87 void appendMessageInSourceCodePaneAtcxx . . $ SourceCodePane#appendMessageInSourceCodePaneAt(909c33aa10af95dd).(int lineNumber, QStringcxx . . $ QString# message);
88 // Post: Appends message to the end of line lineNumber in color color.
89
90 void setSourceCodePaneTextcxx . . $ SourceCodePane#setSourceCodePaneText(7df51288a9ebd664).(QStringcxx . . $ QString# string);
91 // Post: Sets text in source code pane to string.
92
93 void clearSourceCodecxx . . $ SourceCodePane#clearSourceCode(49f6e7a06ebc5aa8).();
94 // Post: Clears the source code pane
95
96 bool isModifiedcxx . . $ SourceCodePane#isModified(c9857a73d68e59ba).();
97 // Post: Returns true if the source code pane has been modified
98
99 void setModifiedFalsecxx . . $ SourceCodePane#setModifiedFalse(49f6e7a06ebc5aa8).();
100 // Post: Sets isModified of the source code pane to false
101
102 QStringcxx . . $ QString# toPlainTextcxx . . $ SourceCodePane#toPlainText(4365c3963150523e).();
103 // Post: Contents of the source code pane are returned
104
105 void setCurrentFilecxx . . $ SourceCodePane#setCurrentFile(7df51288a9ebd664).(QStringcxx . . $ QString# string);
106 // Post: Title bar of the window is set to "Object Code - 'string'"
107
108 void highlightOnFocuscxx . . $ SourceCodePane#highlightOnFocus(49f6e7a06ebc5aa8).();
109 // Post: Highlights the label based on the label window color saved in the UI file
110
111 bool hasFocuscxx . . $ SourceCodePane#hasFocus(c9857a73d68e59ba).();
112 // Post: returns if the pane has focus
113
114 void undocxx . . $ SourceCodePane#undo(49f6e7a06ebc5aa8).();
115 // Post: the last action in the text edit is undone
116
117 void redocxx . . $ SourceCodePane#redo(49f6e7a06ebc5aa8).();
118 // Post: the last undo in the text edit is redone
119
120 bool isUndoablecxx . . $ SourceCodePane#isUndoable(c9857a73d68e59ba).();
121 // Returns the undoability of the text edit
122
123 bool isRedoablecxx . . $ SourceCodePane#isRedoable(c9857a73d68e59ba).();
124 // Returns the redoability of the text edit
125
126 void cutcxx . . $ SourceCodePane#cut(49f6e7a06ebc5aa8).();
127 // Post: selected text in the text edit is cut to the clipboard
128
129 void copycxx . . $ SourceCodePane#copy(49f6e7a06ebc5aa8).();
130 // Post: selected text in the text edit is copied to the clipboard
131
132 void pastecxx . . $ SourceCodePane#paste(49f6e7a06ebc5aa8).();
133 // Post: selected text in the clipboard is pasted to the text edit
134
135 void setReadOnlycxx . . $ SourceCodePane#setReadOnly(b45ddcbc8423892c).(bool b);
136 // Post: the text edit's read only attribute is set to b
137
138 void tabcxx . . $ SourceCodePane#tab(49f6e7a06ebc5aa8).();
139
140 public slotscxx . . $ `<external>/1208926524888476972/qobjectdefs.h:88:14`!:
141 void onFontChangedcxx . . $ SourceCodePane#onFontChanged(19c44da831d1de49).(QFontcxx . . $ QFont# font);
142
143 private:
144 Uicxx . . $ Ui/::SourceCodePanecxx . . $ Ui/SourceCodePane# *uicxx . . $ SourceCodePane#ui.;
145 QListcxx . . $ QList#<Codecxx . . $ Code# *> codeListcxx . . $ SourceCodePane#codeList.;
146 QListcxx . . $ QList#<int> objectCodecxx . . $ SourceCodePane#objectCode.;
147 QStringListcxx . . $ QStringList# assemblerListingListcxx . . $ SourceCodePane#assemblerListingList.;
148 QStringListcxx . . $ QStringList# listingTraceListcxx . . $ SourceCodePane#listingTraceList.;
149 QListcxx . . $ QList#<bool> hasCheckBoxcxx . . $ SourceCodePane#hasCheckBox.;
150
151 PepHighlightercxx . . $ PepHighlighter# *pepHighlightercxx . . $ SourceCodePane#pepHighlighter.;
152
153 void mouseReleaseEventcxx . . $ SourceCodePane#mouseReleaseEvent(702858a82d06265c).(QMouseEventcxx . . $ QMouseEvent# *);
154
155 void mouseDoubleClickEventcxx . . $ SourceCodePane#mouseDoubleClickEvent(702858a82d06265c).(QMouseEventcxx . . $ QMouseEvent# *);
156
157 private slotscxx . . $ `<external>/1208926524888476972/qobjectdefs.h:88:14`!:
158 void setLabelToModifiedcxx . . $ SourceCodePane#setLabelToModified(b45ddcbc8423892c).(bool modified);
159
160 signalscxx . . $ `<external>/1208926524888476972/qobjectdefs.h:89:14`!:
161 void undoAvailablecxx . . $ SourceCodePane#undoAvailable(b45ddcbc8423892c).(bool);
162 void redoAvailablecxx . . $ SourceCodePane#redoAvailable(b45ddcbc8423892c).(bool);
163
164 void labelDoubleClickedcxx . . $ SourceCodePane#labelDoubleClicked(d9b7ee7ebef3c77).(Enucxx . . $ Enu/::EPanecxx . . $ Enu/EPane# pane);
165 };
166
167 #endif // SOURCECODEPANE_H
168