Menu

Relationship names in relationship.php

Cozensweb
2006-06-23
2013-05-29
  • Cozensweb

    Cozensweb - 2006-06-23

    I've decided to have a go at getting descriptive test for relationships in the Relationship chart. I've based my work on the existing patch for adding relationship labels developed at neumont. I have (in english only) added support for the following relationships
    NxGreat Grandfather
    NxGreat Grandmother
    NxGreat Grandson
    NxGreat Granddaughter
    NxGreat Uncle
    NxGreat Aunt
    Nth Cousin
    Nth Cousin M times removed ascending
    Nth Cousin M times removed descending
    The great relationships should work over any number of generations, the cousin relationships I have coded for up to twentieth cousin twenty times removed. I also plan on adding support for in-law relationships soon.

    To take this further I need to understand how relationships are described in other languages - ie how similar or different are they to english.
    I'm no linguist but if anyone would like to have a go at describing other languages I'm happy to consider how to incorporate support. Please contact me either via email or via the forums. The work so far can be viewed at http://cozensweb.co.uk/genealogy/

     
    • Gerry Kroll

      Gerry Kroll - 2006-06-23

      You need to make provision for lineage ("paternal" and "maternal").  It's not wrong to make this distinction in English, although it's commonly not done.

       
    • Cozensweb

      Cozensweb - 2006-07-29

      I've done quite a bit towards this now. I have a fairly full featured English and French implementation. I am also working with Meliza towards Finnish and Hebrew. I've independently made a start on Spanish - although not speaking the language does mean that I don't know how well I'm doing.

      I hope to be in a position to post something back for general use in a few weeks time. It would realy help me out if there is anyone who would liek to collaborate on getting any other languages sorted out by then. If you are able to help then please email me.

      If you want to see progress I have a test page that links to examples of each relationship type in my gedcom. It can be found here http://cozensweb.co.uk/genealogy/reltest.html

      Thanks in advance for any help - even if it is just saying pointing out a single error.

      I'll also post this in the open discussion forum as I got so few responses here.

      Dave

       
    • Nolens Volens

      Nolens Volens - 2006-09-01

      Dave,

      i'd like to assist you with the german translation for the relationships.
      (actually they look like
      "A. SCHRECK is the ur-großvater of C. HELMS"
      which should look like
      "A. SCHRECK ist der Urgroßvater von C. HELMS"

      please tell me what you exactly need 

      Christian

       
    • Philippe Vanpeperstraete

      I could help you with the Dutch translation. What exactly would you like me to provide?

      Philippe

       
    • Cozensweb

      Cozensweb - 2006-09-01

      As a follow up to the postings by vanpepep and nolensvolens I thought that I should make a posting saying where I have got to.

      I have committed internationalised support to SVN for
      wife, husband, brother, all direct descendants, all direct ancestors, aunts and uncles at any generation, cousins upto 20th cousins (more just requires mor translated text), nephews and nieces to any generation, brother in law, sister in law, father in law, mother in law, son, in law, daugher in law, step father mother brother sister, half brother, half sister, and if the first relation is a spouse then two sentences are generated, one describing the relationship of the first person to the spouse and then a second one describing the relationship of the spouse to the second individual. I found that useful when working on parts of my wifes tree and then using the "Show relationship to me chart".

      All of the above can be localised just by translation I believe for the majority of languages. I have committed support english, french (not complete and should be checked by a native speaker), Finnish and Hebrew (thanks Meliza), and portugese (needs completing - thanks for your help laietechie).

      There is also a mechanism within the code to implement language specific functions where the languages expresions for relationships are not representable by direct translation. For example the chinese distinction of elder and younger within many relationships.

      As the relationship is expressed as a sentence some languages also require changing the for of names - for instance the Finnish genitive form. I made a start on this and there is a template function in functions.fi.php - at the moment the body is nulled out - if any finnish speaker fancies having a go then please do.

      I'll fix problems found with this code and assist translators in any way I can - please email me directly.

      The only problems known to me at the moment are to do with incomplete translations and some false identification of relationships - especially in the area of step relationships when the second path between individuals is searched for.

      The specific problems with the great grandparernt translation mentioned by nolensvolens originates from the pre-existing get_sosa_name function. I will be addressing this function and will try to mop up the german implementation when I'm in there.

      In answer to what needs to be done to add support for another language I suggest the following:

      Firstly translate the new text I have added in lang.en.php. Either get the file from SVN or email me and I'll send yo the specific text that should be translated.

      To locate the new text in lang.en.php you should know that the first new text I added was
      $pgv_lang["relationship_male_1_is_the_2_of_3"] = '%1$s is the %2$s of %3$s.';

      and the last that should be translated is

      $pgv_lang["female_cousin_20"]

      place the translated text in the appropriate lang.xx.php file and see how it works.

      If you then have problems where some relationships cannot be properly expressed in your language email me through sourceforge and I'll do my best to assist.

      When it is all working commit the changes back to SVN. If you do not have access and would like me to do that step I'm happy to help. Also if you would like me to assist in developing the translations I'm happy to prototype support for a language on my site and I have a test page linking into my site which may help with proving things out.

      I'll email venpepep and nolensvolens directly to progress German and dutch.

       
    • Cozensweb

      Cozensweb - 2006-09-02

      With help from Vanpepep I have just committed Dutch relationship labels to SVN.

       
    • Barry Schempp

      Barry Schempp - 2006-11-08

      Morning,

      I stopped by your site and saw the work you've done in determining relationships between 2 individuals. Looks great!
      How would I best go about obtaining the code for this? It's not yet released in a final package?

      Thanks,
         -Barry-

       
      • Cozensweb

        Cozensweb - 2006-11-08

        Barry,

        The code is all committed in the current SVN version that you could check out. Or 4.1 beta 1 has recently been released - including the relationship labels.

        Regards Dave

         
        • Patrik Hansson

          Patrik Hansson - 2006-11-09

          Hi Dave
          I have noticed that your changes in the languages files for the relationships makes the translation tool to not function correctly.

          1. The translation tool can not handle your single quote labels
          2. the nested lables are not handle correctly the are stated as empty in english file.

          the comparison tool seems to handle both of the obove case but not tranlation tool.

          regards
          Patrik Hansson

           
          • Cozensweb

            Cozensweb - 2006-11-09

            Patrik,

            Firstly sorry to have introduced a problem.

            The single quotes are unfortunatly essential to the operation of the feature. If the string is included with double quotes the variables held in the sting are expanded as the string is read rather than when it is processed and the functionality fails.

            It will take a while to get round to looking at a fix - I have other things that must take priority for now.

            I would like to raise the question of how the issue should be solved though.

            The tool could be modified to support single quotes for some text and double quotes for other text.

            Or my preference would be to change all of the text to being single quoted and make the translation tool enforce that. The reason for my preference is that php can expand variables inside double quoted strings and so it is as I understand it much slower at parsing double quoted strings. Although this would involve changing many files to perform the edit it could be semi automated with most decent text editors. It would also invlove changes to the translator tools.

             
    • Andrew bLack

      Andrew bLack - 2007-03-27

      I'm from indonesia, how call person in family in bataknese is tricky. let's call person 1 and person 2, all names of relationship are depend in:
      1. Family Tree
      2. Age
      3. Marital Status
      4. Gender
      5. Family Name
      6. Connected from Mother or Father line?
      and so on. And the call will not always two ways. Person 1 call Person 2 "Uncle" and not always Person 2 Call "Niece"

       

Log in to post a comment.