New file format name, minor changes and fixes.
This commit is contained in:
parent
f63e86b78a
commit
620bdfc28c
8 changed files with 75 additions and 44 deletions
|
@ -15,6 +15,8 @@
|
|||
id="SVGRoot"
|
||||
sodipodi:docname="logplotterfile.svg"
|
||||
inkscape:version="1.0.1 (3bc2e813f5, 2020-09-07)">
|
||||
<title
|
||||
id="title849">Logarithm Plotter Icon</title>
|
||||
<defs
|
||||
id="defs10">
|
||||
<linearGradient
|
||||
|
@ -67,16 +69,16 @@
|
|||
borderopacity="1.0"
|
||||
inkscape:pageopacity="0.0"
|
||||
inkscape:pageshadow="2"
|
||||
inkscape:zoom="22.4"
|
||||
inkscape:cx="11.327682"
|
||||
inkscape:cy="10.179403"
|
||||
inkscape:zoom="15.839192"
|
||||
inkscape:cx="31.617327"
|
||||
inkscape:cy="5.2075676"
|
||||
inkscape:document-units="px"
|
||||
inkscape:current-layer="layer1"
|
||||
inkscape:document-rotation="0"
|
||||
showgrid="true"
|
||||
inkscape:window-width="1920"
|
||||
inkscape:window-height="1011"
|
||||
inkscape:window-x="1920"
|
||||
inkscape:window-x="0"
|
||||
inkscape:window-y="0"
|
||||
inkscape:window-maximized="1">
|
||||
<inkscape:grid
|
||||
|
@ -91,8 +93,38 @@
|
|||
<dc:format>image/svg+xml</dc:format>
|
||||
<dc:type
|
||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||
<dc:title />
|
||||
<dc:title>Logarithm Plotter File Icon</dc:title>
|
||||
<dc:date>2021</dc:date>
|
||||
<dc:creator>
|
||||
<cc:Agent>
|
||||
<dc:title>Ad5001</dc:title>
|
||||
</cc:Agent>
|
||||
</dc:creator>
|
||||
<dc:rights>
|
||||
<cc:Agent>
|
||||
<dc:title>(c) Copyright Ad5001 2021</dc:title>
|
||||
</cc:Agent>
|
||||
</dc:rights>
|
||||
<cc:license
|
||||
rdf:resource="http://creativecommons.org/licenses/by-nc-sa/4.0/" />
|
||||
</cc:Work>
|
||||
<cc:License
|
||||
rdf:about="http://creativecommons.org/licenses/by-nc-sa/4.0/">
|
||||
<cc:permits
|
||||
rdf:resource="http://creativecommons.org/ns#Reproduction" />
|
||||
<cc:permits
|
||||
rdf:resource="http://creativecommons.org/ns#Distribution" />
|
||||
<cc:requires
|
||||
rdf:resource="http://creativecommons.org/ns#Notice" />
|
||||
<cc:requires
|
||||
rdf:resource="http://creativecommons.org/ns#Attribution" />
|
||||
<cc:prohibits
|
||||
rdf:resource="http://creativecommons.org/ns#CommercialUse" />
|
||||
<cc:permits
|
||||
rdf:resource="http://creativecommons.org/ns#DerivativeWorks" />
|
||||
<cc:requires
|
||||
rdf:resource="http://creativecommons.org/ns#ShareAlike" />
|
||||
</cc:License>
|
||||
</rdf:RDF>
|
||||
</metadata>
|
||||
<g
|
||||
|
@ -104,37 +136,33 @@
|
|||
style="fill:url(#linearGradient53);fill-opacity:1;stroke:#aaaaaf;stroke-width:0.7;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
|
||||
d="m 4,2 h 13 l 3,3.8181818 V 23 H 4 Z"
|
||||
sodipodi:nodetypes="cccccc" />
|
||||
<g
|
||||
id="g870"
|
||||
transform="translate(-4.5,-1)">
|
||||
<rect
|
||||
style="fill:#000000;fill-rule:evenodd;stroke-width:9.65201;stroke-opacity:0"
|
||||
id="rect1410"
|
||||
width="11"
|
||||
height="1"
|
||||
x="11"
|
||||
y="17" />
|
||||
<rect
|
||||
style="fill:#000000;fill-rule:evenodd;stroke-width:9.65208;stroke-opacity:0"
|
||||
id="rect1412"
|
||||
width="1"
|
||||
height="11"
|
||||
x="15"
|
||||
y="8" />
|
||||
<path
|
||||
style="fill:none;fill-rule:evenodd;stroke:#ff0000;stroke-width:0.975312;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
|
||||
id="path1529"
|
||||
sodipodi:type="arc"
|
||||
sodipodi:cx="11"
|
||||
sodipodi:cy="8"
|
||||
sodipodi:rx="10.012342"
|
||||
sodipodi:ry="9.0123415"
|
||||
sodipodi:start="0"
|
||||
sodipodi:end="1.5707963"
|
||||
sodipodi:arc-type="arc"
|
||||
sodipodi:open="true"
|
||||
d="M 21.012342,8 A 10.012342,9.0123415 0 0 1 11,17.012341" />
|
||||
</g>
|
||||
<rect
|
||||
style="fill:#000000;fill-rule:evenodd;stroke-width:9.65201;stroke-opacity:0"
|
||||
id="rect1410"
|
||||
width="11"
|
||||
height="1"
|
||||
x="6.5"
|
||||
y="16" />
|
||||
<rect
|
||||
style="fill:#000000;fill-rule:evenodd;stroke-width:9.65208;stroke-opacity:0"
|
||||
id="rect1412"
|
||||
width="1"
|
||||
height="11"
|
||||
x="10.5"
|
||||
y="7" />
|
||||
<path
|
||||
style="fill:none;fill-rule:evenodd;stroke:#ff0000;stroke-width:0.97652;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
|
||||
id="path1529"
|
||||
sodipodi:type="arc"
|
||||
sodipodi:cx="6.5"
|
||||
sodipodi:cy="7"
|
||||
sodipodi:rx="10.01174"
|
||||
sodipodi:ry="9.0117397"
|
||||
sodipodi:start="0"
|
||||
sodipodi:end="1.5707963"
|
||||
sodipodi:arc-type="arc"
|
||||
sodipodi:open="true"
|
||||
d="M 16.51174,7 A 10.01174,9.0117397 0 0 1 6.5,16.01174" />
|
||||
<path
|
||||
id="rect899"
|
||||
style="fill:#aaaaaf;fill-opacity:1;stroke:none;stroke-width:0.7;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
|
||||
|
|
Before Width: | Height: | Size: 4.4 KiB After Width: | Height: | Size: 5.5 KiB |
|
@ -2,10 +2,11 @@
|
|||
<mime-info xmlns="http://www.freedesktop.org/standards/shared-mime-info">
|
||||
<mime-type xmlns="http://www.freedesktop.org/standards/shared-mime-info" type="application/x-logarithm-plotter">
|
||||
<comment>Logarithm Plot/Graph</comment>
|
||||
<comment xml:lang="fr">Graphe Logarithmique</comment>
|
||||
<icon name="/home/ad5001/Apps/LogarithmPlotter/linux/logplotterfile.svg"/>
|
||||
<glob-deleteall/>
|
||||
<glob pattern="*.json"/>
|
||||
<glob pattern="*.lgg"/>
|
||||
<glob pattern="*.lgp"/>
|
||||
<glob pattern="*.lpf"/>
|
||||
</mime-type>
|
||||
</mime-info>
|
||||
|
|
|
@ -52,7 +52,7 @@
|
|||
<dc:title>Logarithm Plotter Icon v1.0</dc:title>
|
||||
<cc:license
|
||||
rdf:resource="http://creativecommons.org/licenses/by-nc-sa/4.0/" />
|
||||
<dc:date>27/12/2020</dc:date>
|
||||
<dc:date>2021</dc:date>
|
||||
<dc:creator>
|
||||
<cc:Agent>
|
||||
<dc:title>Ad5001</dc:title>
|
||||
|
@ -60,7 +60,7 @@
|
|||
</dc:creator>
|
||||
<dc:rights>
|
||||
<cc:Agent>
|
||||
<dc:title>(c) Ad5001 2020 - All rights reserved</dc:title>
|
||||
<dc:title>(c) Ad5001 2021 - All rights reserved</dc:title>
|
||||
</cc:Agent>
|
||||
</dc:rights>
|
||||
</cc:Work>
|
||||
|
|
Before Width: | Height: | Size: 4 KiB After Width: | Height: | Size: 4 KiB |
|
@ -24,7 +24,7 @@ D.FileDialog {
|
|||
property bool exportMode: false
|
||||
|
||||
title: exportMode ? "Export Logarithmic Graph file" : "Import Logarithmic Graph file"
|
||||
nameFilters: ["Logarithmic Graph JSON Data (*.lgg)", "Old Logarithmic Graph JSON Data (*.json)", "All files (*)"]
|
||||
nameFilters: ["Logarithmic Graph JSON Data (*.lpf *.lgg)", "Old Logarithmic Graph JSON Data (*.json)", "All files (*)"]
|
||||
|
||||
folder: shortcuts.documents
|
||||
selectExisting: !exportMode
|
||||
|
|
|
@ -94,9 +94,9 @@ ApplicationWindow {
|
|||
LogGraphCanvas {
|
||||
id: drawCanvas
|
||||
anchors.top: parent.top
|
||||
anchors.left: sidebar.right
|
||||
anchors.left: sidebar.inPortrait ? parent.left : sidebar.right
|
||||
height: parent.height
|
||||
width: parent.width - sidebar.position*sidebar.width
|
||||
width: sidebar.inPortrait ? parent.width : parent.width - sidebar.position*sidebar.width
|
||||
x: sidebar.position*sidebar.width
|
||||
|
||||
xmin: settings.xmin
|
||||
|
@ -117,6 +117,8 @@ ApplicationWindow {
|
|||
}
|
||||
|
||||
function saveDiagram(filename) {
|
||||
if(['json', 'lpf', 'lgg'].indexOf(filename.split('.')[filename.split('.').length-1]) == -1)
|
||||
filename += '.lpf'
|
||||
settings.saveFilename = filename
|
||||
var objs = {}
|
||||
for(var objType in Objects.currentObjects){
|
||||
|
|
|
@ -234,7 +234,7 @@ class Function extends ExecutableObject {
|
|||
|
||||
getReadableString() {
|
||||
if(this.displayMode == 'application') {
|
||||
return `${this.name}: ${this.definitionDomain} ⟼ ${this.destinationDomain}\n ${' '.repeat(this.name.length)}x ⟼ ${this.expression.toString()}`
|
||||
return `${this.name}: ${this.definitionDomain} ⟶ ${this.destinationDomain}\n ${' '.repeat(this.name.length)}x ⟼ ${this.expression.toString()}`
|
||||
} else {
|
||||
return `${this.name}(x) = ${this.expression.toString()}\nD${Utils.textsub(this.name)} = ${this.definitionDomain}`
|
||||
}
|
||||
|
|
2
run.py
2
run.py
|
@ -93,7 +93,7 @@ engine.addImportPath(os.path.realpath(os.path.join(os.getcwd(), "qml")))
|
|||
engine.load(os.path.realpath(os.path.join(os.getcwd(), "qml", "LogGraph.qml")))
|
||||
|
||||
os.chdir(pwd)
|
||||
if len(argv) > 0 and os.path.exists(argv[-1]) and argv[-1].split('.')[-1] in ['json', 'lgg']:
|
||||
if len(argv) > 0 and os.path.exists(argv[-1]) and argv[-1].split('.')[-1] in ['json', 'lgg', 'lpf']:
|
||||
print(argv[-1])
|
||||
engine.rootObjects()[0].loadDiagram(argv[-1])
|
||||
os.chdir(os.path.dirname(os.path.realpath(__file__)))
|
||||
|
|
BIN
win/logplotter.ico
Normal file
BIN
win/logplotter.ico
Normal file
Binary file not shown.
After Width: | Height: | Size: 181 KiB |
Loading…
Reference in a new issue