Commit 9209196d authored by payno's avatar payno Committed by Henri Payno
Browse files

[orangecontrib] refactoring to get three groups: utils (io...), pymca xas and larch exafs

parent ebce6a2a
......@@ -26,7 +26,7 @@ import sysconfig
# Category metadata.
# Category icon show in the menu
ICON = "icons/pymca.png"
ICON = "icons/xas.png"
# Background color for category background in menu
# and widget icon background in workflow.
......@@ -50,13 +50,23 @@ WIDGET_HELP_PATH = (
)
# Entry point for main Orange categories/widgets discovery
def widget_discovery(discovery):
import pkg_resources
dist = pkg_resources.get_distribution("xas")
pkgs = [
"orangecontrib.xas.widgets.pymca",
"orangecontrib.xas.widgets.larch",
"orangecontrib.xas.widgets.utils",
]
for pkg in pkgs:
discovery.process_category_package(pkg, distribution=dist)
import unittest
def suite():
test_suite = unittest.TestSuite()
from .test import suite as widgets_suite
test_suite.addTest(widgets_suite())
return test_suite
# coding: utf-8
###########################################################################
# Copyright (C) 2016 European Synchrotron Radiation Facility
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in
# all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
# THE SOFTWARE.
#
#############################################################################
NAME = 'xas_larch'
ID = 'orangecontrib.xas.widgets.larch'
DESCRIPTION = 'larch orange widget'
LONG_DESCRIPTION = 'larch exafs processes'
ICON = "icons/larch.png"
BACKGROUND = "light-green"
PRIORITY = 3
# coding: utf-8
###########################################################################
# Copyright (C) 2016 European Synchrotron Radiation Facility
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in
# all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
# THE SOFTWARE.
#
#############################################################################
NAME = 'xas_pymca'
ID = 'orangecontrib.xas.widgets.pymca'
DESCRIPTION = 'pymca orange widget'
LONG_DESCRIPTION = 'pymca XAS processes'
ICON = "icons/pymca.png"
BACKGROUND = "light-green"
PRIORITY = 2
......@@ -44,7 +44,7 @@ from orangecontrib.xas.process import _PyMcaProcessForOrangeMixIn, \
ProcessRunnable
from xas.core.types import XASObject, Spectrum
from xas.gui.XasObjectViewer import XasObjectViewer, _CurveOperation, ViewType
from ..progress import QProgress
from orangecontrib.xas.progress import QProgress
_logger = logging.getLogger(__file__)
......
......@@ -44,7 +44,7 @@ from orangecontrib.xas.process import _PyMcaProcessForOrangeMixIn, \
ProcessRunnable
from xas.core.types import XASObject, Spectrum
from xas.gui.XasObjectViewer import XasObjectViewer, _CurveOperation, ViewType
from ..progress import QProgress
from orangecontrib.xas.progress import QProgress
_logger = logging.getLogger(__file__)
......
......@@ -39,7 +39,7 @@ import xas.core.process.pymca.k_weight
from orangecontrib.xas.process import _PyMcaProcessForOrangeMixIn, \
ProcessRunnable
from xas.core.types import XASObject
from ..progress import QProgress
from orangecontrib.xas.progress import QProgress
_logger = logging.getLogger(__file__)
......
......@@ -44,7 +44,7 @@ from orangecontrib.xas.process import _PyMcaProcessForOrangeMixIn
from orangecontrib.xas.process import ProcessRunnable
from xas.core.types import XASObject, Spectrum
from xas.gui.XasObjectViewer import XasObjectViewer, _CurveOperation, ViewType
from ..progress import QProgress
from orangecontrib.xas.progress import QProgress
_logger = logging.getLogger(__file__)
......
# coding: utf-8
###########################################################################
# Copyright (C) 2016 European Synchrotron Radiation Facility
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in
# all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
# THE SOFTWARE.
#
#############################################################################
NAME = 'xas_utils'
ID = 'orangecontrib.xas.widgets.utils'
DESCRIPTION = 'common utils for xas'
LONG_DESCRIPTION = 'common tools compatible with pymca and larch add-on'
ICON = "icons/xas.svg"
BACKGROUND = "light-blue"
PRIORITY = 2
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="64px"
height="64px"
id="svg2985"
version="1.1"
inkscape:version="0.48.5 r10040"
sodipodi:docname="New document 2">
<defs
id="defs2987">
<linearGradient
id="linearGradient3769">
<stop
id="stop3777"
offset="0"
style="stop-color:#b93939;stop-opacity:0.8347826;" />
<stop
style="stop-color:#d74c4c;stop-opacity:0.5043478;"
offset="1"
id="stop3773" />
</linearGradient>
<linearGradient
inkscape:collect="always"
xlink:href="#linearGradient3769"
id="linearGradient3775"
x1="-55.954544"
y1="8.0573578"
x2="54.5"
y2="8.0573578"
gradientUnits="userSpaceOnUse" />
</defs>
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="5.5"
inkscape:cx="32"
inkscape:cy="32"
inkscape:current-layer="layer1"
showgrid="true"
inkscape:document-units="px"
inkscape:grid-bbox="true"
inkscape:window-width="1920"
inkscape:window-height="1098"
inkscape:window-x="0"
inkscape:window-y="31"
inkscape:window-maximized="1" />
<metadata
id="metadata2990">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<g
id="layer1"
inkscape:label="Layer 1"
inkscape:groupmode="layer">
<path
style="fill:none;stroke:url(#linearGradient3775);stroke-width:0.8;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;stroke-miterlimit:4;stroke-dasharray:none"
d="M -0.18181818,36.181818 C 10.181818,2.5454545 12.181818,73.272727 25.454545,61.272727 38.727273,49.272727 54,0 54,0 L 0.72727273,-46.545455 -55.454545,32.727273 -18.545455,50 z"
id="path2999"
inkscape:connector-curvature="0" />
<text
xml:space="preserve"
style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Amiri;-inkscape-font-specification:Amiri"
x="6.4311514"
y="41.609375"
id="text2993"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan2995"
x="6.4311514"
y="41.609375"
style="font-size:30px">XAS</tspan></text>
</g>
</svg>
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment