Skip to content
Snippets Groups Projects
Commit 767a3b7c authored by ojs1g14's avatar ojs1g14
Browse files

Removed section heading bug

parent d9144a96
Branches main
No related tags found
No related merge requests found
......@@ -17,6 +17,18 @@ from PyQt5.QtWidgets import (QAction, QApplication, QGridLayout,
class AmpScanGUI(QMainWindow):
"""
Generates an GUI for handling stl data. Window is derived from QT.
More detailed description...
Example
-------
Perhaps an example implementation:
>>> from AmpScan.AmpScanGUI import AmpScanGUI
"""
def __init__(self, parent = None):
super(AmpScanGUI, self).__init__()
......@@ -38,6 +50,17 @@ class AmpScanGUI(QMainWindow):
self.show()
def chooseOpenFile(self):
"""
Handles importing of stls into the GUI.
More writing...
Note
----
@Josh_Steer if no stl is selected then the window crashes!
"""
self.fname = QFileDialog.getOpenFileName(self, 'Open file',
filter="Meshes (*.stl)")
if self.AmpObj is not None:
......@@ -50,6 +73,10 @@ class AmpScanGUI(QMainWindow):
self.renWin.renderActors([self.AmpObj.actor,])
def chooseSocket(self):
"""
Button in GUI.
"""
self.sockfname = QFileDialog.getOpenFileName(self, 'Open file',
filter="Meshes (*.stl)")
self.socket = AmpObject(self.sockfname[0], stype='socket')
......
......@@ -205,7 +205,7 @@ Solution:
A \_static file containing css templates does exist in docs\_build\\html but sphinx looks for it in docs. I copied the file to this location and the error went away.
Tracback 4:
Traceback 4:
\begin{lstlisting}[language=Python]
WARNING: toctree references unknown document 'source/AmpScan.analyse.analyseMixin.create_slices
......@@ -217,5 +217,17 @@ Solution:
'numpydoc' was removed from the extension list and replaced with 'sphinx.ext.napoleon'.
Traceback 5:
\begin{lstlisting}[language=Python]
WARNING: Unexpected section title.
Bug
---
\end{lstlisting}
Solution:
Napoleon (sphinx support for numpy or google docstrings) only recognises a specific subset of headings of which "Bug" is not one. Allowed headings are outlined here; \url{http://www.sphinx-doc.org/en/stable/ext/napoleon.html}. I changed the offending section to "Note" which rendered fine.
\end{document}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment