From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from int-mx1.corp.redhat.com (int-mx1.corp.redhat.com [172.16.44.254]) by listman.redhat.com (Postfix) with ESMTP id CB5243F000 for ; Mon, 26 Nov 2001 14:05:41 -0500 (EST) Received: from mail.redhat.com (mail.redhat.com [199.183.24.239]) by int-mx1.corp.redhat.com (8.11.6/8.11.6) with SMTP id fAQJ5fp02066 for ; Mon, 26 Nov 2001 14:05:41 -0500 Received: (from mail@localhost) by mail.redhat.com (8.11.0/8.8.7) id fAQJ5ft15915 for blinux-list@listman.redhat.com; Mon, 26 Nov 2001 14:05:41 -0500 Received: from lowblow.svc.tds.net (lowblow.svc.tds.net [204.246.1.39]) by mail.redhat.com (8.11.0/8.8.7) with ESMTP id fAQJ5fw15910 for ; Mon, 26 Nov 2001 14:05:41 -0500 Received: from jumbo ([216.170.140.224]) by lowblow.svc.tds.net with SMTP id <20011126190540.QKFA1072.lowblow@jumbo> for ; Mon, 26 Nov 2001 13:05:40 -0600 Message-ID: <00b901c176a5$ab9c1960$e08caad8@tds.net> From: "John J. Boyer" To: References: Subject: Re: brltty and simultaneous grade 2 translation Date: Mon, 26 Nov 2001 13:10:42 -0500 X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.50.4133.2400 X-MIMEOLE: Produced By Microsoft MimeOLE V5.50.4133.2400 X-Loop: blinux-list@redhat.com Sender: blinux-list-admin@redhat.com Errors-To: blinux-list-admin@redhat.com X-BeenThere: blinux-list@redhat.com X-Mailman-Version: 2.0.1 Precedence: bulk Reply-To: blinux-list@redhat.com List-Help: List-Post: List-Subscribe: , List-Id: Linux for blind general discussion List-Unsubscribe: , List-Archive: Dave, I prefer a pointer and a length also. I think it would be a good idea to have a global variable containing the length of the Braille display, so it wouldn't have to be passed. I can pass back an aray of the position in the input buffer of each character in the output buffer, but I feel a bit uncomfortable about doing cut and paste in Grade 2 because Grade 2 isn't 1 for 1. I would probably turn off Grade 2 before doing cut and paste. Perhaps it would be better if we take this discussion of-list and work out the programming details and the format of the translation tables between us. John Computers to Help People, Inc. http://www.chpi.org 825 East Johnson; Madison, WI 53703 ----- Original Message ----- From: "Dave Mielke" To: Sent: Monday, November 26, 2001 12:45 Subject: Re: brltty and simultaneous grade 2 translation > [quoted lines by John J. Boyer on November 26, 2001, at 11:39] > > >I am assuming that brltty would pass a pointer to a position in a string. > > I have a thing against null-terminated strings, and would prefer to pass in an > address and a length. > > >The Grade 2 translation routine would then translate until it reached the > >end of the string or until it had enough to fill the Braille display. > > Yes, although that'd mean that an additional parameter, i.e. an integer set to > the braille window width, would also need to be passed to the translation > routine. > > >If it > >found that the last word would not fit on the display it would backtrack to > >the beginning of that word and just leave a few blanks at the end of the > >display. > > That's definitely the simplest, most predictable, and least error prone way to > do it. > > >In any case, it would pass back a pointer to the place in the input > >string where translation should resume, or perhaps an integer count of the > >number of characters in the input string that it translated. > > I'd prefer an integer count. This count should include any trailing blanks. > > >If the pointer into the input string indicating where the translation was to > >begin happened to be in the middle of a word the translator would just > >process the rest of the word, whatever that might turn out to be, instead of > >trying to find the beginning of the word and probably producing some nasty > >bugs. > > That's certainly a good starting point. If, with it working that way, there are > no complaints, then it'll prove itself to be an adequate solution. > > >I think that cut and paste should simply not be attempted if the Grade 2 > >translation is on. Brltty should refuse to carry it out and should display a > >message asking the user to turn grade 2 translation off. > > I'd sure like it to work, as I dislike denying functionality based on > implementation restrictions. It could easily be made to work if the translation > routine were to pass back an offset into the input string for each character in > the output buffer. > > -- > Dave Mielke | 2213 Fox Crescent | I believe that the Bible is the > Phone: 1-613-726-0014 | Ottawa, Ontario | Word of God. Please contact me > EMail: dave@mielke.cc | Canada K2A 1H7 | if you're concerned about Hell. > > > > _______________________________________________ > Blinux-list mailing list > Blinux-list@redhat.com > https://listman.redhat.com/mailman/listinfo/blinux-list >