Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix coregistration button positions #819

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 20 additions & 20 deletions invesalius/constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -854,22 +854,22 @@
TR3 = wx.NewIdRef()
SET = wx.NewIdRef()

FIDUCIAL_LABELS = ["Left Ear: ", "Right Ear: ", "Nose: "]
FIDUCIAL_LABELS = ["Right Ear: ", "Left Ear: ", "Nose: "]
FIDUCIAL_REGISTRATION_ORDER = [0, 2, 1]
IMAGE_FIDUCIALS = [
{
"button_id": IR1,
"label": "Left Ear",
"fiducial_name": "LE",
"label": "Right Ear",
"fiducial_name": "RE",
"fiducial_index": 0,
"tip": _("Select left ear in image"),
"tip": _("Select right ear in image"),
},
{
"button_id": IR2,
"label": "Right Ear",
"fiducial_name": "RE",
"label": "Left Ear",
"fiducial_name": "LE",
"fiducial_index": 1,
"tip": _("Select right ear in image"),
"tip": _("Select left ear in image"),
},
{
"button_id": IR3,
Expand All @@ -883,17 +883,17 @@
TRACKER_FIDUCIALS = [
{
"button_id": TR1,
"label": "Left Ear",
"fiducial_name": "LE",
"label": "Right Ear",
"fiducial_name": "RE",
"fiducial_index": 0,
"tip": _("Select left ear with spatial tracker"),
"tip": _("Select right ear with spatial tracker"),
},
{
"button_id": TR2,
"label": "Right Ear",
"fiducial_name": "RE",
"label": "Left Ear",
"fiducial_name": "LE",
"fiducial_index": 1,
"tip": _("Select right ear with spatial tracker"),
"tip": _("Select left ear with spatial tracker"),
},
{
"button_id": TR3,
Expand All @@ -904,7 +904,7 @@
},
]

BTNS_IMG_MARKERS = {IR1: {0: "LEI"}, IR2: {1: "REI"}, IR3: {2: "NAI"}}
BTNS_IMG_MARKERS = {IR1: {0: "REI"}, IR2: {1: "LEI"}, IR3: {2: "NAI"}}

OBJL = wx.NewIdRef()
OBJR = wx.NewIdRef()
Expand All @@ -917,16 +917,16 @@
OBJECT_FIDUCIALS = [
{
"fiducial_index": 0,
"button_id": OBJL,
"label": _("Left"),
"tip": _("Select left object fiducial"),
},
{
"fiducial_index": 1,
"button_id": OBJR,
"label": _("Right"),
"tip": _("Select right object fiducial"),
},
{
"fiducial_index": 1,
"button_id": OBJL,
"label": _("Left"),
"tip": _("Select left object fiducial"),
},
{
"fiducial_index": OBJECT_FIDUCIAL_ANTERIOR,
"button_id": OBJA,
Expand Down
2 changes: 1 addition & 1 deletion invesalius/data/markers/marker.py
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ def from_dict(self, d):
if "marker_type" in d:
marker_type = d["marker_type"]
else:
if d["label"] in ["LEI", "REI", "NAI"]:
if d["label"] in ["REI", "LEI", "NAI"]:
marker_type = MarkerType.FIDUCIAL.value

elif orientation == [None, None, None]:
Expand Down
11 changes: 1 addition & 10 deletions invesalius/gui/frame.py
Original file line number Diff line number Diff line change
Expand Up @@ -790,16 +790,7 @@ def ShowGettingStarted(self):
"""
Show getting started window.
"""
session = ses.Session()
if session.GetConfig("language") == "pt_BR":
user_guide = "user_guide_pt_BR.pdf"
else:
user_guide = "user_guide_en.pdf"

path = os.path.join(inv_paths.DOC_DIR, user_guide)
if sys.platform == "darwin":
path = r"file://" + path
webbrowser.open(path)
webbrowser.open("https://invesalius.github.io/docs/user_guide/user_guide.html")

def ShowImportDicomPanel(self):
"""
Expand Down