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

Parents and spouse labels in relationship view #1843

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

DaveSch-gramps
Copy link
Contributor

Have the labels for Father, Mother, Parent set for the active person regardless of the gender of the person set in the Families' Father/Parent1, Mother/Parent2 position.

Have the the labels for Husband, Wife, Spouse, Partner display for families depending on the gender of the spouse. Husband, Wife, Spouse are used for 'legal' marriages (Married, Civil Union) and Partner for non-legal status.

@DaveSch-gramps
Copy link
Contributor Author

DaveSch-gramps commented Jan 4, 2025

Bug #13554

@Nick-Hall Nick-Hall added the bug label Jan 4, 2025
@wroldwiedbwe
Copy link

@Nick-Hall The linked bug is actually a feature request: Have the Parent and Spouse labels dynamically change based upon genders and legal status of marriage don't they go in master?

@Nick-Hall
Copy link
Member

Yes, implementing a feature request would usually be regarded as an enhancement and should be in the master branch.

@giotodibondone
Copy link

@wroldwiedbwe Related discussion

As per nick yes, also has implication on documentation for 5.2.x as you'd have older versions in same series showing something different from the user manual if 5.2.x was changed not something anybody wants!

@giotodibondone
Copy link

Also as per @DaveSch-gramps on the forum he mentions "Not sure how to make labels say “Stepfather”, “Stepmother”"

So probably needs a bit more work and testing before being accepted on gramps/master?

@DaveSch-gramps
Copy link
Contributor Author

DaveSch-gramps commented Jan 5, 2025

Do I close this PR so that I can rebuild the branch on master ?? or is there a way to move it.

@Nick-Hall Nick-Hall force-pushed the Parents-and-Spouse-labels branch from 336e7b1 to f08fad4 Compare January 9, 2025 18:56
@Nick-Hall Nick-Hall changed the base branch from maintenance/gramps52 to master January 9, 2025 18:56
@Nick-Hall Nick-Hall added enhancement and removed bug labels Jan 9, 2025
@Nick-Hall
Copy link
Member

Rebased onto the master branch.

Comment on lines +1120 to +1125
if father == Person.MALE:
parent1 = _("Father")
elif father == Person.FEMALE:
parent1 = _("Mother")
else:
parent1 = _("Parent")
Copy link
Contributor

Choose a reason for hiding this comment

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

Consider moving this block into a function to avoid duplication.
Something like this:

parent1 = self.__get_parent_label(father)
parent2 = self.__get_parent_label(mother)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Admittedly, I am not a coder. I can hack what others have thought up.

The process I have is to determine the label for the person slotted in the Father/Parent1 slot based upon their gender and then do the same for the person in the Mather/Parent2 slot.

Using my code, I actually have a Female in the F/P1 slot and the father/sperm donor in the M/P2 slot.\ for the labels Mother and Father.

@Nick-Hall Nick-Hall changed the title Parents and spouse labels Parents and spouse labels in relationship view Jan 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants