pFad - Phone/Frame/Anonymizer/Declutterfier! Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

URL: http://github.com/FOSSEE/eSim/commit/d7ba0a2d47e0a76a24d1c9d86837ec6505883b72

er-b69241e157469407.css" /> Merge pull request #197 from rahulp13/master · FOSSEE/eSim@d7ba0a2 · GitHub
Skip to content

Commit d7ba0a2

Browse files
authored
Merge pull request #197 from rahulp13/master
Fix incorrect status reporting on NgVeri UI terminal
2 parents 61a5e71 + 91b51ef commit d7ba0a2

File tree

1 file changed

+15
-12
lines changed

1 file changed

+15
-12
lines changed

src/maker/NgVeri.py

Lines changed: 15 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,6 @@ class NgVeri(QtWidgets.QWidget):
4242

4343
# initialising the variables
4444
def __init__(self, filecount):
45-
print(self)
4645
QtWidgets.QWidget.__init__(self)
4746
# Maker.addverilog(self)
4847
self.obj_Appconfig = Appconfig()
@@ -99,7 +98,8 @@ def addverilog(self):
9998
return
10099

101100
self.fname = Maker.verilogFile[self.filecount]
102-
model = ModelGeneration.ModelGeneration(self.fname, self.entry_var[0])
101+
currentTermLogs = QtWidgets.QTextEdit()
102+
model = ModelGeneration.ModelGeneration(self.fname, currentTermLogs)
103103
file = (os.path.basename(self.fname)).split('.')[0]
104104
if self.entry_var[1].findText(file) == -1:
105105
self.entry_var[1].addItem(file)
@@ -139,35 +139,38 @@ def addverilog(self):
139139
self.nghdl_home + "/lib/ngspice/"
140140
)
141141
except FileNotFoundError as err:
142-
self.entry_var[0].append(
142+
currentTermLogs.append(
143143
"Error in copying Ngveri code model: " + str(err)
144144
)
145145

146-
terminalLog = self.entry_var[0].toPlainText()
147-
if "error" not in terminalLog.lower():
148-
self.entry_var[0].append('''
146+
if "error" not in currentTermLogs.toPlainText().lower():
147+
currentTermLogs.append('''
149148
<p style=\" font-size:16pt; font-weight:1000;
150149
color:#00FF00;\"> Model Created Successfully!
151150
</p>
152151
''')
153152

154-
return
155-
156153
except BaseException as err:
157-
self.entry_var[0].append(
154+
currentTermLogs.append(
158155
"Error in Ngspice code model generation " +
159156
"from Verilog: " + str(err)
160157
)
161158

162-
terminalLog = self.entry_var[0].toPlainText()
163-
if "error" in terminalLog.lower():
164-
self.entry_var[0].append('''
159+
if "error" in currentTermLogs.toPlainText().lower():
160+
currentTermLogs.append('''
165161
<p style=\" font-size:16pt; font-weight:1000;
166162
color:#FF0000;\">There was an error during model creation,
167163
<br/>Please rectify the error and try again!
168164
</p>
169165
''')
170166

167+
self.entry_var[0].append(currentTermLogs.toHtml())
168+
169+
# Force scroll the terminal widget at bottom
170+
self.entry_var[0].verticalScrollBar().setValue(
171+
self.entry_var[0].verticalScrollBar().maximum()
172+
)
173+
171174
def addfile(self):
172175
'''
173176
This function is used to add additional files required

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad © 2024 Your Company Name. All rights reserved.





Check this box to remove all script contents from the fetched content.



Check this box to remove all images from the fetched content.


Check this box to remove all CSS styles from the fetched content.


Check this box to keep images inefficiently compressed and original size.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy