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

ENH: Improve terminology selector #7691

Merged
merged 1 commit into from
Apr 15, 2024

Conversation

lassoan
Copy link
Contributor

@lassoan lassoan commented Apr 12, 2024

Allow deselecting anatomic region and anatomic region modifier ("None" and "No region modifier" items are added to the comboboxes). Before this commit, once a region or modifier was selected, it was not possible to deselect it.

image

Add the anatomic region to the default generated name, because often it is the only difference between segment names (e.g., "bleeding in Cerebellum" and "bleeding in Subdural space").

image

To reduce occurrences of undefined (gray) color: if color is not specified for the selected type modifier then use the color of the non-modified type.

Added a few missing translation functions to allow full internationalization.

Allow deselecting anatomic region and anatomic region modifier ("None" and "No region modifier" items are added to the comboboxes). Before this commit, once a region or modifier was selected, it was not possible to deselect it.

Add the anatomic region to the default generated name, because often it is the only difference between segment names (e.g., "bleeding in Cerebellum" and "bleeding in Subdural space").

To reduce occurrences of undefined (gray) color: if color is not specified for the selected type modifier then use the color of the non-modified type.

Added a few missing translation functions to allow full internationalization.
@lassoan lassoan added this to the Slicer 5.7 milestone Apr 12, 2024
@lassoan lassoan requested a review from cpinter April 12, 2024 13:21
@lassoan lassoan self-assigned this Apr 12, 2024
if (entry->GetTypeObject()->GetHasModifiers() && entry->GetTypeModifierObject() && entry->GetTypeModifierObject()->GetCodeValue())
{
name += QString(", %1").arg(entry->GetTypeModifierObject()->GetCodeMeaning());
//: For formatting of terminology entry with a modifier. %1 is structure name (e.g., "Kidney"), %2 is modifier (e.g., "Left")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why the colon? //:

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

//: is the syntax for message to translators, shown in Weblate and Qt Linguist, for the message in the line below.

@cpinter
Copy link
Member

cpinter commented Apr 15, 2024

These changes look reasonable, thank you!

@lassoan lassoan merged commit 5c44b86 into Slicer:main Apr 15, 2024
6 checks passed
@lassoan lassoan deleted the improve-terminology-selector branch April 15, 2024 12:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants