Re: LyX cannot entirely change the document language - now bug 4062
Dov Feldstern wrote: Helge Hafting wrote: [...] Not strange at all. Document text that isn't explicitly set to some language, is in the document language and changes if that language is ever changed. This is very convenient. I can see that this will be different with languages that uses different writing systems, such as english and hebrew. Changing one to another might be meaningless with no common letters. But then, anyone wanting to type hebrew will notice right away that their new document is set to english. I guess this is the crux of our disagreement... As you yourself said, it'll never happen that one types anything in Hebrew and only later realizes that he's been typing in English, it's just not possible. But what does often happen is that you start typing a mixture of English and Hebrew, and then at some point realize that this should really be a Hebrew document, so you switch the language of the document, but you certainly don't expect all existing English paragraphs to become Hebrew... I agree that transforming english to hebrew is wrong. In that case, I don't dispute the validity of this bug report. But I do want to clarify that when it is fixed, care should be taken not to change the behavior regarding RTL languages. I'll add a note to this effect to the bug report. I don't think it is RTL is the only special case. We sure don't want to force transformations between latin/greek/russian either. Ideally, I guess the determination of whether or not to preserve the language of default text when switching the document language from A to B should be something like this: if A and B have the same alphabet (which I don't think we can check --- but what about if we would use the encoding as a surrogate --- would that work for you?) then all default language text should remain default, i.e., it is now considered to be in language B. However, if B has a different alphabet (encoding) than A, then all text marked as default should now be explicitly marked as A. Does that sound right? Yes. Transformation may be impossible with different encodings - that is why they are different. So lets not even try in those cases. Now, utf8 can encode anything, so theoretically, a utf8 document could be changed from any language to any language. But latex don't support this today. And if it ever does, this change should actually work so it can be allowed. Note, however, that this could be very confusing, because sometimes the language will change, and other times it won't, and the user may not understand why it is or isn't in any specific case... It will always work for some combinations of languages, and never for other combinations. Few people regularly work with *many* languages. Those that do, will probably see the sense in that they can correct english to french but not turn it into hebrew or greek. Helge Hafting
Re: LyX cannot entirely change the document language - now bug 4062
Dov Feldstern wrote: Helge Hafting wrote: [...] Not strange at all. Document text that isn't explicitly set to some language, is in the "document language" and changes if that language is ever changed. This is very convenient. I can see that this will be different with languages that uses different writing systems, such as english and hebrew. Changing one to another might be meaningless with no common letters. But then, anyone wanting to type hebrew will notice right away that their new document is set to english. I guess this is the crux of our disagreement... As you yourself said, it'll never happen that one types anything in Hebrew and only later realizes that he's been typing in English, it's just not possible. But what does often happen is that you start typing a mixture of English and Hebrew, and then at some point realize that this should really be a Hebrew document, so you switch the language of the document, but you certainly don't expect all existing English paragraphs to become Hebrew... I agree that transforming english to hebrew is wrong. In that case, I don't dispute the validity of this bug report. But I do want to clarify that when it is fixed, care should be taken not to change the behavior regarding RTL languages. I'll add a note to this effect to the bug report. I don't think it is RTL is the only special case. We sure don't want to force transformations between latin/greek/russian either. Ideally, I guess the determination of whether or not to preserve the language of "default" text when switching the document language from A to B should be something like this: if A and B have the same alphabet (which I don't think we can check --- but what about if we would use the encoding as a surrogate --- would that work for you?) then all "default language" text should remain "default", i.e., it is now considered to be in language B. However, if B has a different alphabet (encoding) than A, then all text marked as "default" should now be explicitly marked as A. Does that sound right? Yes. Transformation may be impossible with different encodings - that is why they are different. So lets not even try in those cases. Now, utf8 can encode anything, so theoretically, a utf8 document could be changed from any language to any language. But latex don't support this today. And if it ever does, this change should actually work so it can be allowed. Note, however, that this could be very confusing, because sometimes the language will change, and other times it won't, and the user may not understand why it is or isn't in any specific case... It will always work for some combinations of languages, and never for other combinations. Few people regularly work with *many* languages. Those that do, will probably see the sense in that they can correct "english" to "french" but not turn it into "hebrew" or "greek". Helge Hafting
Re: LyX cannot entirely change the document language - now bug 4062
Helge Hafting wrote: Dov Feldstern wrote: Helge Hafting wrote: Paul Smith wrote: Thanks, Steve. If it is not a bug, then many users like me -- I guess -- would be very happy if they were given the option of choosing as global the change of language, i.e., affecting all paragraphs and not only the the new ones. Such an option already exists: select whatever you want to change --- the entire document, if that's what you want --- and then set the language from Edit-Text Style-Customized, Exactly what users don't want. First - this can be lots of work if you have many pages to change with lots of little foreign snippets inbetween that you don't want to change. (quoutes, tech terms and so on in a different language.) Second, starting to write a document with the wrong language is common for people who work with several languages. You don't notice the wrong language at all if both languages uses the same writing system, which is the case for the many european languages that work with latin1. You don't see it until you run the final spellcheck, or notice weird hyphenation when doing view-dvi. or using the language xxx lfun from the minibuffer. Switching the language of a document may have other effects, such as determining language-dependent document-wide settings, as well as determine the default language when you start typing, but it would seem very strange to me if it also change the language of already typed in text. Not strange at all. Document text that isn't explicitly set to some language, is in the document language and changes if that language is ever changed. This is very convenient. I can see that this will be different with languages that uses different writing systems, such as english and hebrew. Changing one to another might be meaningless with no common letters. But then, anyone wanting to type hebrew will notice right away that their new document is set to english. I guess this is the crux of our disagreement... As you yourself said, it'll never happen that one types anything in Hebrew and only later realizes that he's been typing in English, it's just not possible. But what does often happen is that you start typing a mixture of English and Hebrew, and then at some point realize that this should really be a Hebrew document, so you switch the language of the document, but you certainly don't expect all existing English paragraphs to become Hebrew... In that case, I don't dispute the validity of this bug report. But I do want to clarify that when it is fixed, care should be taken not to change the behavior regarding RTL languages. I'll add a note to this effect to the bug report. Ideally, I guess the determination of whether or not to preserve the language of default text when switching the document language from A to B should be something like this: if A and B have the same alphabet (which I don't think we can check --- but what about if we would use the encoding as a surrogate --- would that work for you?) then all default language text should remain default, i.e., it is now considered to be in language B. However, if B has a different alphabet (encoding) than A, then all text marked as default should now be explicitly marked as A. Does that sound right? Note, however, that this could be very confusing, because sometimes the language will change, and other times it won't, and the user may not understand why it is or isn't in any specific case... Dov
Re: LyX cannot entirely change the document language - now bug 4062
Helge Hafting wrote: Dov Feldstern wrote: Helge Hafting wrote: Paul Smith wrote: Thanks, Steve. If it is not a bug, then many users like me -- I guess -- would be very happy if they were given the option of choosing as global the change of language, i.e., affecting all paragraphs and not only the the new ones. Such an option already exists: select whatever you want to change --- the entire document, if that's what you want --- and then set the language from "Edit->Text Style->Customized", Exactly what users don't want. First - this can be lots of work if you have many pages to change with lots of little foreign snippets inbetween that you don't want to change. (quoutes, tech terms and so on in a different language.) Second, starting to write a document with the wrong language is common for people who work with several languages. You don't notice the wrong language at all if both languages uses the same writing system, which is the case for the many european languages that work with latin1. You don't see it until you run the final spellcheck, or notice weird hyphenation when doing view->dvi. or using the "language xxx" lfun from the minibuffer. Switching the language of a document may have other effects, such as determining language-dependent document-wide settings, as well as determine the "default" language when you start typing, but it would seem very strange to me if it also change the language of already typed in text. Not strange at all. Document text that isn't explicitly set to some language, is in the "document language" and changes if that language is ever changed. This is very convenient. I can see that this will be different with languages that uses different writing systems, such as english and hebrew. Changing one to another might be meaningless with no common letters. But then, anyone wanting to type hebrew will notice right away that their new document is set to english. I guess this is the crux of our disagreement... As you yourself said, it'll never happen that one types anything in Hebrew and only later realizes that he's been typing in English, it's just not possible. But what does often happen is that you start typing a mixture of English and Hebrew, and then at some point realize that this should really be a Hebrew document, so you switch the language of the document, but you certainly don't expect all existing English paragraphs to become Hebrew... In that case, I don't dispute the validity of this bug report. But I do want to clarify that when it is fixed, care should be taken not to change the behavior regarding RTL languages. I'll add a note to this effect to the bug report. Ideally, I guess the determination of whether or not to preserve the language of "default" text when switching the document language from A to B should be something like this: if A and B have the same alphabet (which I don't think we can check --- but what about if we would use the encoding as a surrogate --- would that work for you?) then all "default language" text should remain "default", i.e., it is now considered to be in language B. However, if B has a different alphabet (encoding) than A, then all text marked as "default" should now be explicitly marked as A. Does that sound right? Note, however, that this could be very confusing, because sometimes the language will change, and other times it won't, and the user may not understand why it is or isn't in any specific case... Dov
Re: LyX cannot entirely change the document language - now bug 4062
Dov Feldstern wrote: Helge Hafting wrote: Paul Smith wrote: Thanks, Steve. If it is not a bug, then many users like me -- I guess -- would be very happy if they were given the option of choosing as global the change of language, i.e., affecting all paragraphs and not only the the new ones. Such an option already exists: select whatever you want to change --- the entire document, if that's what you want --- and then set the language from Edit-Text Style-Customized, Exactly what users don't want. First - this can be lots of work if you have many pages to change with lots of little foreign snippets inbetween that you don't want to change. (quoutes, tech terms and so on in a different language.) Second, starting to write a document with the wrong language is common for people who work with several languages. You don't notice the wrong language at all if both languages uses the same writing system, which is the case for the many european languages that work with latin1. You don't see it until you run the final spellcheck, or notice weird hyphenation when doing view-dvi. or using the language xxx lfun from the minibuffer. Switching the language of a document may have other effects, such as determining language-dependent document-wide settings, as well as determine the default language when you start typing, but it would seem very strange to me if it also change the language of already typed in text. Not strange at all. Document text that isn't explicitly set to some language, is in the document language and changes if that language is ever changed. This is very convenient. I can see that this will be different with languages that uses different writing systems, such as english and hebrew. Changing one to another might be meaningless with no common letters. But then, anyone wanting to type hebrew will notice right away that their new document is set to english. I think this is a bug, in the paste mechanism. You can change the language of all paragraphs (except those with an exlicit foreign language) by changing the document language. But this only works if you _wrote_ the document that way. If you _pasted_ as little as a single word from a document with another language, then this screws up. (_Writing_ that foreign word and using edit-text style to mark it foreign will work - you can still change the document language and have everything else change with it.) This is very strange --- I see the behavior you're describing with regard to, say, English and French, but not (thank goodness) with regard to English and Hebrew: In other words, when I have typed (or pasted) in something in English, and the switch the document language to Hebrew, then what's already been typed or pasted in remains in English, as I would expect. The behavior that's occurring with English and French seems very strange to me, what I would expect is for all text that's already been typed in to remain in its original language. If the user explicitly wants to switch the language of text that's already been typed in, it can be done as explained above. It can, but the concept of text having the document language is nice, and it sure helps when correcting mistakes. Consider writing a french article, containing lots of quotes in various other languages. Then the spellchecker comes up with english because the document language was at its (mistaken) default. Changing the document language then fixes everything - the main text is now french. People working with several european languages are common - the default language will be the one they uses most, and sometimes they will forget to set the correct language from the start. Helge Hafting
Re: LyX cannot entirely change the document language - now bug 4062
Dov Feldstern wrote: Helge Hafting wrote: Paul Smith wrote: Thanks, Steve. If it is not a bug, then many users like me -- I guess -- would be very happy if they were given the option of choosing as global the change of language, i.e., affecting all paragraphs and not only the the new ones. Such an option already exists: select whatever you want to change --- the entire document, if that's what you want --- and then set the language from "Edit->Text Style->Customized", Exactly what users don't want. First - this can be lots of work if you have many pages to change with lots of little foreign snippets inbetween that you don't want to change. (quoutes, tech terms and so on in a different language.) Second, starting to write a document with the wrong language is common for people who work with several languages. You don't notice the wrong language at all if both languages uses the same writing system, which is the case for the many european languages that work with latin1. You don't see it until you run the final spellcheck, or notice weird hyphenation when doing view->dvi. or using the "language xxx" lfun from the minibuffer. Switching the language of a document may have other effects, such as determining language-dependent document-wide settings, as well as determine the "default" language when you start typing, but it would seem very strange to me if it also change the language of already typed in text. Not strange at all. Document text that isn't explicitly set to some language, is in the "document language" and changes if that language is ever changed. This is very convenient. I can see that this will be different with languages that uses different writing systems, such as english and hebrew. Changing one to another might be meaningless with no common letters. But then, anyone wanting to type hebrew will notice right away that their new document is set to english. I think this is a bug, in the "paste" mechanism. You can change the language of all paragraphs (except those with an exlicit foreign language) by changing the document language. But this only works if you _wrote_ the document that way. If you _pasted_ as little as a single word from a document with another language, then this screws up. (_Writing_ that foreign word and using edit->text style to mark it foreign will work - you can still change the document language and have everything else change with it.) This is very strange --- I see the behavior you're describing with regard to, say, English and French, but not (thank goodness) with regard to English and Hebrew: In other words, when I have typed (or pasted) in something in English, and the switch the document language to Hebrew, then what's already been typed or pasted in remains in English, as I would expect. The behavior that's occurring with English and French seems very strange to me, what I would expect is for all text that's already been typed in to remain in its original language. If the user explicitly wants to switch the language of text that's already been typed in, it can be done as explained above. It can, but the concept of text having the "document language" is nice, and it sure helps when correcting mistakes. Consider writing a french article, containing lots of quotes in various other languages. Then the spellchecker comes up with english because the document language was at its (mistaken) default. Changing the document language then fixes everything - the main text is now french. People working with several european languages are common - the default language will be the one they uses most, and sometimes they will forget to set the correct language from the start. Helge Hafting
Re: LyX cannot entirely change the document language - now bug 4062
Paul Smith wrote: Thanks, Steve. If it is not a bug, then many users like me -- I guess -- would be very happy if they were given the option of choosing as global the change of language, i.e., affecting all paragraphs and not only the the new ones. I think this is a bug, in the paste mechanism. You can change the language of all paragraphs (except those with an exlicit foreign language) by changing the document language. But this only works if you _wrote_ the document that way. If you _pasted_ as little as a single word from a document with another language, then this screws up. (_Writing_ that foreign word and using edit-text style to mark it foreign will work - you can still change the document language and have everything else change with it.) I tested and reported this as bug 4062 Helge Hafting
Re: LyX cannot entirely change the document language - now bug 4062
Helge Hafting wrote: Paul Smith wrote: Thanks, Steve. If it is not a bug, then many users like me -- I guess -- would be very happy if they were given the option of choosing as global the change of language, i.e., affecting all paragraphs and not only the the new ones. Such an option already exists: select whatever you want to change --- the entire document, if that's what you want --- and then set the language from Edit-Text Style-Customized, or using the language xxx lfun from the minibuffer. Switching the language of a document may have other effects, such as determining language-dependent document-wide settings, as well as determine the default language when you start typing, but it would seem very strange to me if it also change the language of already typed in text. I think this is a bug, in the paste mechanism. You can change the language of all paragraphs (except those with an exlicit foreign language) by changing the document language. But this only works if you _wrote_ the document that way. If you _pasted_ as little as a single word from a document with another language, then this screws up. (_Writing_ that foreign word and using edit-text style to mark it foreign will work - you can still change the document language and have everything else change with it.) This is very strange --- I see the behavior you're describing with regard to, say, English and French, but not (thank goodness) with regard to English and Hebrew: In other words, when I have typed (or pasted) in something in English, and the switch the document language to Hebrew, then what's already been typed or pasted in remains in English, as I would expect. The behavior that's occurring with English and French seems very strange to me, what I would expect is for all text that's already been typed in to remain in its original language. If the user explicitly wants to switch the language of text that's already been typed in, it can be done as explained above. I tested and reported this as bug 4062 Helge Hafting
Re: LyX cannot entirely change the document language - now bug 4062
Paul Smith wrote: Thanks, Steve. If it is not a bug, then many users like me -- I guess -- would be very happy if they were given the option of choosing as global the change of language, i.e., affecting all paragraphs and not only the the new ones. I think this is a bug, in the "paste" mechanism. You can change the language of all paragraphs (except those with an exlicit foreign language) by changing the document language. But this only works if you _wrote_ the document that way. If you _pasted_ as little as a single word from a document with another language, then this screws up. (_Writing_ that foreign word and using edit->text style to mark it foreign will work - you can still change the document language and have everything else change with it.) I tested and reported this as bug 4062 Helge Hafting
Re: LyX cannot entirely change the document language - now bug 4062
Helge Hafting wrote: Paul Smith wrote: Thanks, Steve. If it is not a bug, then many users like me -- I guess -- would be very happy if they were given the option of choosing as global the change of language, i.e., affecting all paragraphs and not only the the new ones. Such an option already exists: select whatever you want to change --- the entire document, if that's what you want --- and then set the language from "Edit->Text Style->Customized", or using the "language xxx" lfun from the minibuffer. Switching the language of a document may have other effects, such as determining language-dependent document-wide settings, as well as determine the "default" language when you start typing, but it would seem very strange to me if it also change the language of already typed in text. I think this is a bug, in the "paste" mechanism. You can change the language of all paragraphs (except those with an exlicit foreign language) by changing the document language. But this only works if you _wrote_ the document that way. If you _pasted_ as little as a single word from a document with another language, then this screws up. (_Writing_ that foreign word and using edit->text style to mark it foreign will work - you can still change the document language and have everything else change with it.) This is very strange --- I see the behavior you're describing with regard to, say, English and French, but not (thank goodness) with regard to English and Hebrew: In other words, when I have typed (or pasted) in something in English, and the switch the document language to Hebrew, then what's already been typed or pasted in remains in English, as I would expect. The behavior that's occurring with English and French seems very strange to me, what I would expect is for all text that's already been typed in to remain in its original language. If the user explicitly wants to switch the language of text that's already been typed in, it can be done as explained above. I tested and reported this as bug 4062 Helge Hafting