Not getting autosuggest of attributes from XLIFF modules in XLIFF files

Having trouble installing <oXygen/>? Got a bug to report? Post it all here.
simonech
Posts: 3

Not getting autosuggest of attributes from XLIFF modules in XLIFF files

Wed Jun 07, 2017 9:09 pm

When editing a new XLIFF file, I get autosuggestions of attributes in the Xliff Core module, and autosuggestion of elements from both core and optional xliff modules, but I don't get auto suggestions for attributes that are in modules.
This happens either if I reference the namespace or not.

The xsd is hooked correctly because if I mistype the value of the attribute I get the correct validation error.

Happens on Oxygen v19

Step to reproduce:
  1. Create a new XLIFF 2.0 file from template. You get this file

    Code: Select all

    <xliff version='2.0'
        xmlns='urn:oasis:names:tc:xliff:document:2.0' srcLang="en" trgLang="fr">
        <file id="f1">
            <unit id="u1">
                <segment>
                    <source></source>
                </segment>
            </unit>
        </file>
    </xliff>

  2. Start typing a < after the file element
  3. You get a dropdown which contains all allowed elements, from the main ns and from all other namespaces
  4. Now start typing something inside the unit element: here you only get attribute defined in the main NS, not from modules

You can notice the same behaviour in the side panels "attributes" and "elements": attributes just show the elements from the core, while elements all possible elements.

Same error happens even if I specify the Namespace for the module, for example:

Code: Select all

<xliff version='2.0'
    xmlns='urn:oasis:names:tc:xliff:document:2.0'
    xmlns:fs='urn:oasis:names:tc:xliff:fs:2.0'
    srcLang="en" trgLang="fr">
    <file id="f1">
        <unit id="u1" >
            <segment>
                <source></source>
            </segment>
        </unit>
    </file>
</xliff>


Even with this code, if I start typing "fs:" I get no autosuggestion.

Not sure where the issue is, whether is in Oxygen or in the XLIFF framework implementation.

Thank you
Simone
Radu
Posts: 5088

Re: Not getting autosuggest of attributes from XLIFF modules in XLIFF files

Fri Jun 09, 2017 10:54 am

Hi Simone,

I confirm this is a bug in Oxygen, according to how the XLiff XML Schema is constructed Oxygen should propose in its content completion window all possible attributes from all other namespaces for the <unit> element.
If you add those attributes manually like for example the validation will not report any problem:

Code: Select all

<xliff version='2.0'
    xmlns='urn:oasis:names:tc:xliff:document:2.0' srcLang="en" trgLang="fr" xmlns:bla="urn:oasis:names:tc:xliff:sizerestriction:2.0">
    <file id="f1">
        <unit id="u1" bla:equivStorage="blabla">
            <segment>
                <source></source>
            </segment>
        </unit>
    </file>
</xliff>


so it's just a problem of the entries we propose in the content completion window and the attributes view.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
simonech
Posts: 3

Re: Not getting autosuggest of attributes from XLIFF modules in XLIFF files

Tue Jun 13, 2017 3:39 pm

Yeah, indeed...
once added the attributes manually, the validation works fine.

Hopefully such bug will be fixed in the future :)

Cheers
Simone
Radu
Posts: 5088

Re: Not getting autosuggest of attributes from XLIFF modules in XLIFF files

Tue Jun 13, 2017 3:42 pm

Hi Simone,

Sorry for the inconvenience.
We started working on the fix and it should be available in Oxygen 19.1 (Autumn this year).

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
Radu
Posts: 5088

Re: Not getting autosuggest of attributes from XLIFF modules in XLIFF files

Mon Oct 02, 2017 1:28 pm

Hi,

Just to update this thread, Oxygen 19.1 was released and it should contain a fix for the reported problem.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com

Return to “Common Problems”

Who is online

Users browsing this forum: No registered users and 4 guests