[I7 6L02] French extension

I’ve found this document bitbucket.org/informfr/i7-frenc … Syntax.pdf but it does not say anything about possible unicode problems.

It seems that the only way to go is a pre-parser, as suggested above. This choice will solve a lot of other localization issues. For example, a pre-parser could translate “La descrizione è” in “The description is”, “Invece di” in “Instead of” and so on, providing a complete localization decades before it would be available in the real thing :wink:

Here is also the error report found in the log file:

[code]Problem C8NoSuchVerb issued from inform7/Chapter 8/Traverse for Assertions.w, line 350

→ In the sentence ‘The Hall è a room’ (source text, line 3), I can’t find a
verb that I know how to deal with.
[/code]

Leo, I installed de Italian Extension and compiled your example.

Everything was ok here.

Perhaps your OS / IDE ?

Source:

[code]“Title” by Author (in Italian)

The Hall è a room. “Una piccola stanza in una sola lettera.”[/code]

Story:

[code]
Title
An Interactive Fiction by Author
Release 1 / Serial number 140719 / Inform 7 build 6L02 (I6/v6.33 lib 6/12N) SD

Hall
Una piccola stanza in una sola lettera.

[/code]

[spoiler]D:\Inform7\Compilers\ni
-rules “D:\Inform7\Inform7\Extensions” -package “D:\Mis_documentos\Inform\Projects\2014 I7\Italian verbo una letra.inform” -extension=ulx
Inform 7 build 6L02 has started.
I’ve now read your source text, which is 17 words long.
I’ve also read Standard Rules by Graham Nelson, which is 42560 words long.
I’ve also read English Language by Graham Nelson, which is 2130 words long.
I’ve also read Italian Language by Massimo Stella, which is 13251 words long.
I’ve also read Text Capture by Eric Eve, which is 1076 words long.
I’ve also read Punctuation Removal by Emily Short, which is 906 words long.

The 17-word source text has successfully been translated into an intermediate
description which can be run through Inform 6 to complete compilation.
There were 1 room and 1 thing.
Inform 7 has finished.

D:\Inform7\Compilers\inform6
-wSDG +include_path=…\Source,.\ auto.inf output.ulx
Inform 6.33 for Win32 (10th May 2014)
In: 1 source code files 87255 syntactic lines
68087 textual lines 2487640 characters (ISO 8859-1 Latin1)
Allocated:
8954 symbols (maximum 20000) 14086640 bytes of memory
Out: Glulx story file 1.140719 (777K long):
21 classes (maximum 200) 43 objects (maximum 640)
234 global vars (maximum 512) 88329 variable/array space (maximum 180000)
170 verbs (maximum 255) 469 dictionary entries (maximum 2000)
316 grammar lines (version 2) 1035 grammar tokens (unlimited)
102 actions (maximum 200) 37 attributes (maximum 56)
40 common props (maximum 256) 26 individual props (unlimited)
184276 characters used in text 141335 bytes compressed (rate 0.766)
0 abbreviations (maximum 64) 3119 routines (unlimited)
93986 instructions of code 49254 sequence points
116992 bytes writable memory used 678400 bytes read-only memory used
795392 bytes used in machine 1072946432 bytes free in machine
Compiled with 1804 suppressed warnings
Completed in 1 seconds

Compiler finished with code 0[/spoiler]

I’m working in Win7.

Incredible! I’m working in Win7, too.
I’ll try again… there is hope!

It works! (On Win7)

But now I’ve realized that in my previous tries I’ve used Inform 7 on a PC with WinXP!
So the problem is not Inform 7, but WinXP (and I think that very few are still using WinXP out there).

I’m sorry for all these unuseful posts!

For the ADMIN: Feel free to delete all my previous posts.

This is still a bug worth tracking down, when Preform is fully supported. It could still be a mistake in ni, and we don’t know that the problem only appears in WinXP.

Here another thing to note: (probably you know it)

Now I try to use spanish names for new kinds (for my game or extension), like:

El elemento is a kind of thing. [The element is a kind of thing]

In spanish, the plural of “elemento” is “elementos”. (a default plural ending)

But when compile, the index/kinds section set: elemento (plural elementoes), not elemento.

ie: using elementos in the source will produce a compiler fail, because I7 expects elementoes like a plural.
And for printing porpouses idem.

That is because I7 applies the english rules (in this case *to in in Syntax.preform), instead of the spanish one.

Workaround?

El elemento is a kind of thing. The plural of elemento is elementos.
Or…

The element is a kind of thing. [first the pure english definition] Element translates into Spanish as elemento.[second the spanish layer]

The second one is not a workround. It is the way (I think) to do these stuffs right now. Furthermore it will allow to facilitate the work for extension-translators, because all of us know english (more or less), and is more easy the “english->my-language” process that “another-language->my-language” process.

Here is another problem with the “Italian Extension”. I post in the “French” thread because it could be related.

I see these lines in the preform “Italian Language”:

<definite-article> ::= /b/ il/lo/l' | [singular, masculine] /c/ la/l' | [singular, feminine] /d/ le | [plural, feminine] /e/ gli/i [plural, masculine (by default)]
But when I write this source:

[code]“Title” by Author (in Italian)

La Hall è una stanza.

When play begins:
repeat with T running through things:
say “[T] has [grammatical gender of T].”

I piatti sono una cosa dentro la Hall.
Le padelle sono una cosa dentro la Hall.
Le pentole (f) sono una cosa dentro la Hall.
[/code]

I get:

[code]te has masculine gender.
piatti has masculine gender.
padelle has neuter gender.
pentole has feminine gender.

Title
An Interactive Fiction by Author
Release 1 / Serial number 140722 / Inform 7 build 6L02 (I6/v6.33 lib 6/12N) SD

Hall
Qui puoi vedere dei piatti, un padelle e delle pentole.
[/code]

It seems that “Le” (plural and feminine determinative article) does not work without the “(f)” specification, no matter what the preform says.

I know that in French “les” can’t specify gender, but in italian there is “Le” (feminine plural) and “I” (masculine plural). Is the italian preform wrong?

Thanks for any answer!

It seems yep. :wink:

According to the doc , you must respect the ‘order’ of the ‘productions’ within the preform tries.

In this case, the order (ie, the letter) is: (9/pro 5 in the pdf)

<definite-article> ::= /a/ [for singular, neuter] /b/ [for singular, masculine] /c/ [for singular, feminine] /d/ [for plural, neuter ] /e/ [plural, masculine (by default)] /f/ [plural, femenine]

I see that you are assigning ´Le´ to plural neuter, not plural femenine (f case).

Thank you! I trusted Massimo’s work so much that I didn’t notice the wrong assignment. Sorry!

I’ve recently used in my (italian) sources the possibility to define verbs like that:

  In Italian contenere is a verb meaning to contain.

So I can write:

  La scatola contiene una penna. [The box contains a pen.]

and it works gracefully.

Now I have read in the Preform Grammar docs that there is also the possibility to define the meaning of adjectives (“is an adjective meaning”).

So I tried:

  In Italian aperto is an adjective meaning open.

but this form does not work. As far as you know, is it implemented yet? If it is, which is the correct formulation? Thank you in advance!

Well, it seems that the current release can’t assign meanings to adjectives.

However, I realized that there is a simpler solution to use italian (or any other Language) adjectives with standard kinds (well, it’s not an idea too difficult to get, but I’ve realized it only recently).

For example, in “Italian Language” one defines:

  A contenitore chiuso apribile is a kind of container. It is usually closed and openable.

So an italian author can write in her code in plain italian:

  La scatola è un contenitore chiuso apribile nella sala da pranzo.

(“scatola” means box and “sala da pranzo” means dining room)

instead of the mixed italian-english:

  The scatola is a closed openable container in the sala da pranzo.

Or one could write “che si può aprire” instead of “apribile”, that sounds even better.

Defining in “Italian Language” (or any other language) all the most important combination of kinds and properties, brings the internationalization of source code a step further even in this release of Inform 7.

You quite right, it seems that feature is turn off (only works for game’s output).

It’s a sin, in fact the workaround described two posts above is not so versatile as a translation of the adjectives (intended as properties of objects) would be.

Anyway, it seems that there is a lot of work going on (at least) in Spanish, French and Italian extensions. I hope that Graham will notice all these efforts: the Champollion project’s guidelines are around since 2011 and it seems to me that there are enough programmers (for each language) to develop them some steps further.

A long time has past since the last post, but hey, we did so much work on the French extension that I have to report the progress made!

First, as a late answer to the question about the adjectives: it is true that the “official” way does not work, but I found a workaround yesterday:

A thing can be mettable. [that's the wearable property.] The mettable property translates into I6 as "clothing".
And so on with the other adjectives. All the English adjectives have then a French counterpart, but they all remain synchronized because they point to the same I6 property than in English, so it seems it doesn’t cause any problems.

Also, I have translated all the phrases (in fact, I just copied the relevant section from the Standard Rules and translated it).

And finally, I have copied the Syntax.preform file into an extension and translated it so one can write his source entirely in French.
Not everything works, but now it is possible to write

[code]Comprendre “arracher [quelque chose]” comme pulling.
[Understand “draw [something] out” as pulling.]

Un support peut être grand ou petit. Un support est généralement petit.
[A supporter can be big or small. A supporter is usually small.][/code]
I’ve put all these modifications in separate extensions for the moment, until all works perfectly.

But all this makes me wonder: have I gone to fast? Are we supposed to wait for that Rosetta project Graham Nelson will write before I can include all this in the French Language extension ? Because I don’t know if the syntax file will change a lot meanwhile (and also because I bet my traductions aren’t not all good).

Anyway, I have attached the source of one of my games I’ve rewritten. You won’t be able to compile it because I haven’t attached the syntax, adjectives and phrasebook extensions. It’s just here so you can see how one can write his source in French.

If someone has got a solution to translate the action names, the rulebook names and the properties like the printed name, then nearly all of the source will be in French!
templenaga-fr.txt (34.7 KB)

good job monsiuer!

Actually, it’s “monsieur”, señor. :stuck_out_tongue:

But seriously, do you think I should include it in the French Language extension, or should I wait?

well, according to Champollion project (and my interpretation):

Phase1: Language of play by a set of good-quality extension for all the main european languages currently supported. That includes new 6L02 language features.

Phase2:Language of the source, by Roseta text (by Graham) . A version in each language.

Phase3:Preform syntax in each language that allow I7 compiles the Roseta text.

Teorically, Ph2 and Ph3 are in the future.

But, I think it is a good initiative make some local stuff with Ph2 and Ph3.
(in fact, in the past, we had the spanish version of I7 using hacks-obscure methods, till Graham published the oficial one).

Yeah, that’s what I think too. But since I believe we have no news of the German and Swedish translations, I wonder when that Phase 2 will begin.

Well, I think I’ll wrap up all I did extra in a single other extension (so we’ll have the “official” French Language Extension and an “advanced and experimental” French features extensions) and I’ll wait.

Meanwhile, I suggest you collect a group of ninja-beta-testers to try to crash the French-engine of your extension.