MCPcopy Create free account
hub / github.com/pyqtgraph/pyqtgraph / getExampleContent

Method getExampleContent

pyqtgraph/examples/ExampleApp.py:551–559  ·  view source on GitHub ↗
(self, filename)

Source from the content-addressed store, hash-verified

549
550 @lru_cache(100)
551 def getExampleContent(self, filename):
552 if filename is None:
553 self.ui.codeView.clear()
554 return
555 if os.path.isdir(filename):
556 filename = os.path.join(filename, '__main__.py')
557 with open(filename, "r") as currentFile:
558 text = currentFile.read()
559 return text
560
561 def codeEdited(self):
562 self.codeBtn.show()

Callers 2

filterByContentMethod · 0.95
showFileMethod · 0.95

Calls 2

clearMethod · 0.45
joinMethod · 0.45

Tested by

no test coverage detected