Re: Windows Vista Speech Recognition and Cygwin/X

2009-01-10 Thread Jon TURNEY

Paul Loewenstein wrote:
The XWin server  uses primarily hardware scan codes for interpreting the 
windows WM_KEYDOWN and WM_SYSKEYDOWN  messages. Unfortunately, Vista 
speech recognition (WSR) doesn't bother to fill in the scancode field in 
the lParam entry.  Neither does SendKeys.SendWait(),  which is what 
Vocola 3, a recently released supplement to WSR, uses to send input to 
applications.


To work around these Microsoft bugs, I modified winkeybd.c as follows:

void
winTranslateKey (WPARAM wParam, LPARAM lParam, int *piScanCode)
{

 intiKeyFixup = g_iKeyMap[wParam * WIN_KEYMAP_COLS + 1];
 intiKeyFixupEx = g_iKeyMap[wParam * WIN_KEYMAP_COLS + 2];
 intiParamScanCode = LOBYTE (HIWORD (lParam));


to

void
winTranslateKey (WPARAM wParam, LPARAM lParam, int *piScanCode)
{

 HKLdwhkl = GetKeyboardLayout(0);

 intiKeyFixup = g_iKeyMap[wParam * WIN_KEYMAP_COLS + 1];
 intiKeyFixupEx = g_iKeyMap[wParam * WIN_KEYMAP_COLS + 2];

 intiParamScanCode = MapVirtualKeyEx (wParam, 
/*MAPVK_VK_TO_VSC*/0, dwhkl);


so that the scan code is regenerated from the keycode.


diff is your friend :-)

An initial test appears to work. However, it is not clear to me whether 
I have introduced some subtle bugs. For example, its correctness depends 
on extended codes having the same scan code as the non-extended 
equivalent on all keyboard layouts.


How about writing it in the following form, that should address that concern, 
if I've understood correctly (in all cases, assuming 0 is never a valid scancode)


$ quilt diff
Index: xorg-server-1.5.3/xserver/hw/xwin/winkeybd.c
===
--- xorg-server-1.5.3.orig/xserver/hw/xwin/winkeybd.c   2009-01-05 
23:50:04.0 +
+++ xorg-server-1.5.3/xserver/hw/xwin/winkeybd.c2009-01-10 
21:55:40.0 +

@@ -80,6 +80,12 @@
   int  iKeyFixupEx = g_iKeyMap[wParam * WIN_KEYMAP_COLS + 2];
   int  iParamScanCode = LOBYTE (HIWORD (lParam));

+  /* WM_ key messages faked by speech recognizers don't have a scan code... */
+  if (iParamScanCode == 0)
+{
+  iParamScanCode = MapVirtualKeyEx(wParam, /*MAPVK_VK_TO_VSC*/0, 
GetKeyboardLayout(0));

+}
+
   /* Branch on special extended, special non-extended, or normal key */
   if ((HIWORD (lParam) & KF_EXTENDED) && iKeyFixupEx)
 *piScanCode = iKeyFixupEx;

Can someone tell me if I've broken anything?  Or suggest a more robust 
fix?  It would be nice to be able to release it rather than having a 
privately distributed modification solely for Vista speech recognition.


Well, my keyboard seems to still work with the above change.  I don't think 
there will be a problem including a patch like this, provided we can be fairly 
confident it hasn't broken normal keyboards :-)



--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/



RE: Windows Vista

2008-08-26 Thread Thomas Dickey

On Tue, 26 Aug 2008, Phil Betts wrote:


Monson Hayes wrote on Sunday, August 24, 2008 12:51 PM::

[snip]






Fatal server error:
could not open default font 'fixed'


It's pretty obvious that this is the reason it's failed, and googling
for this would have found the answer.  Whilst I could give you the
definitive solution, it's such a frequently asked question, and I get
tired of repeating myself.  The answers are already out there, so I
think it's up to you to do the work.

If you don't know how use google to search the mail archives, try
adding "site:cygwin.com inurl:ml/cygwin-xfree" (without the quotes)
to the query.

Phil
This email has been scanned by Ascribe PLC using Microsoft Antigen for Exchange.




..by which one deduces that you've pasted the whole message from 
someplace.  (I guess it saves your time ;-)


--
Thomas E. Dickey
http://invisible-island.net
ftp://invisible-island.net

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/



RE: Windows Vista

2008-08-26 Thread Phil Betts
Monson Hayes wrote on Sunday, August 24, 2008 12:51 PM::

[snip]
 
> Fatal server error:
> could not open default font 'fixed'

It's pretty obvious that this is the reason it's failed, and googling 
for this would have found the answer.  Whilst I could give you the 
definitive solution, it's such a frequently asked question, and I get 
tired of repeating myself.  The answers are already out there, so I 
think it's up to you to do the work.

If you don't know how use google to search the mail archives, try 
adding "site:cygwin.com inurl:ml/cygwin-xfree" (without the quotes) 
to the query.

Phil
This email has been scanned by Ascribe PLC using Microsoft Antigen for Exchange.

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/



Re: Windows Vista

2008-08-25 Thread Brian Wisti
To clarify, Cygwin/X worked fine for me when I was running 32 bit
Vista, but I had to resort to the XMing solution under AMD64.

Kind Regards,

Brian Wisti

On Mon, Aug 25, 2008 at 2:24 PM, Scott Fordin <[EMAIL PROTECTED]> wrote:
> Cygwin does indeed run on 32-bit versions of Windows Vista.
> Don't know about 64-bit versions. In my experience, there
> are a few catches to getting Cygwin to work on Vista:
>
>   1. Run the Cygwin setup as Administrator and in XP
>  Compatibility Mode.
>
>   2. I had better luck when I did the install in two
>  stages: First, I just downloaded the packages, then
>  I ran setup again and chose the install from local
>  repository option.
>
>   3. After installation, run Cygwin's rebaseall command
>  from an ash (not bash) shell.
>
>   4. When you finally run the Cygwin bash shell for real,
>  be sure to use Vista's "Run as Administrator" option.
>
>   5. Also make sure that your firewall is not blocking
>  Xwin.exe or bash.exe.
>
> FWIW, the Xming X server works just fine on Vista, and you
> can use Xming as your X Server when running PuTTY or many if
> not all of the Cygwin X-based apps.
>
> Hope this helps,
>
> Scott
>
> Monson Hayes wrote:
>> Not sure how to reply to a thread, but here are the details of what
>> happens when I try to run Cygwin/X.  First, I would like to comment
>> that the following was suggested:
>>
>> Be sure to set up $DISPLAY in your .bashrc:
>>
>> export DISPLAY=localhost:0.0
>>
>> What is interesting, is in my installation I cannot find a .bashrc
>> file, although I did find one in my Windows XP installation.
>>
>> I am told to look at the XWin.log file on my computer running Windows
>>  Vista when I get the following fatal error:
>>
>> "A fatal error has occurred and Cygwin/X will now exit Releast
>> 6.8.99.901-4 XWin was started with the following command llin
>>
>> /usr/X11R6/bin/XWin -multiwindow - clipboard -silent-dup-error
>>
>> The XWin.log file is:
>>
>> (WW) /tmp mounted int textmode _XSERVTransmkdir: ERROR: euid !=
>> 0,directory /tmp/.X11-unix will not be created. (II) XF86Config is
>> not supported (II) See http://x.cygwin.com/docs/faq/cygwin-x-faq.html
>> for more information winAdjustVideoModeShadowGDI - Using Windows
>> display depth of 32 bits per pixel winAllocateFBShadowGDI - Creating
>> DIB with width: 1680 height: 1050 depth: 32 winInitVisualsShadowGDI -
>> Masks 00ff ff00 00ff BPRGB 8 d 24 bpp 32 null screen fn
>> ReparentWindow null screen fn RestackWindow InitQueue - Calling
>> pthread_mutex_init InitQueue - pthread_mutex_init returned InitQueue
>> - Calling pthread_cond_init InitQueue - pthread_cond_init returned
>> winInitMultiWindowWM - Hello winMultiWindowXMsgProc - Hello
>> winInitMultiWindowWM - Calling pthread_mutex_lock ()
>> winMultiWindowXMsgProc - Calling pthread_mutex_lock () MIT-SHM
>> extension disabled due to lack of kernel support XFree86-Bigfont
>> extension local-client optimization disabled due to lack of shared
>> memory support in the kernel (--) Setting autorepeat to delay=500,
>> rate=31 (--) winConfigKeyboard - Layout: "0409" (0409) (--)
>> Using preset keyboard for "English (USA)" (409), type "4" (--) 8
>> mouse buttons found Could not init font path element
>> /usr/X11R6/lib/X11/fonts/CID/, removing from list!
>>
>> Fatal server error: could not open default font 'fixed'
>>
>> -- Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
>> Problem reports:   http://cygwin.com/problems.html Documentation:
>> http://x.cygwin.com/docs/ FAQ:
>> http://x.cygwin.com/docs/faq/
>>
>
>
> --
> Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
> Problem reports:   http://cygwin.com/problems.html
> Documentation: http://x.cygwin.com/docs/
> FAQ:   http://x.cygwin.com/docs/faq/
>
>

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/



Re: Windows Vista

2008-08-25 Thread Scott Fordin
Cygwin does indeed run on 32-bit versions of Windows Vista.
Don't know about 64-bit versions. In my experience, there
are a few catches to getting Cygwin to work on Vista:

   1. Run the Cygwin setup as Administrator and in XP
  Compatibility Mode.

   2. I had better luck when I did the install in two
  stages: First, I just downloaded the packages, then
  I ran setup again and chose the install from local
  repository option.

   3. After installation, run Cygwin's rebaseall command
  from an ash (not bash) shell.

   4. When you finally run the Cygwin bash shell for real,
  be sure to use Vista's "Run as Administrator" option.

   5. Also make sure that your firewall is not blocking
  Xwin.exe or bash.exe.

FWIW, the Xming X server works just fine on Vista, and you
can use Xming as your X Server when running PuTTY or many if
not all of the Cygwin X-based apps.

Hope this helps,

Scott

Monson Hayes wrote:
> Not sure how to reply to a thread, but here are the details of what 
> happens when I try to run Cygwin/X.  First, I would like to comment
> that the following was suggested:
> 
> Be sure to set up $DISPLAY in your .bashrc:
> 
> export DISPLAY=localhost:0.0
> 
> What is interesting, is in my installation I cannot find a .bashrc
> file, although I did find one in my Windows XP installation.
> 
> I am told to look at the XWin.log file on my computer running Windows
>  Vista when I get the following fatal error:
> 
> "A fatal error has occurred and Cygwin/X will now exit Releast
> 6.8.99.901-4 XWin was started with the following command llin
> 
> /usr/X11R6/bin/XWin -multiwindow - clipboard -silent-dup-error
> 
> The XWin.log file is:
> 
> (WW) /tmp mounted int textmode _XSERVTransmkdir: ERROR: euid !=
> 0,directory /tmp/.X11-unix will not be created. (II) XF86Config is
> not supported (II) See http://x.cygwin.com/docs/faq/cygwin-x-faq.html
> for more information winAdjustVideoModeShadowGDI - Using Windows
> display depth of 32 bits per pixel winAllocateFBShadowGDI - Creating
> DIB with width: 1680 height: 1050 depth: 32 winInitVisualsShadowGDI -
> Masks 00ff ff00 00ff BPRGB 8 d 24 bpp 32 null screen fn
> ReparentWindow null screen fn RestackWindow InitQueue - Calling
> pthread_mutex_init InitQueue - pthread_mutex_init returned InitQueue
> - Calling pthread_cond_init InitQueue - pthread_cond_init returned 
> winInitMultiWindowWM - Hello winMultiWindowXMsgProc - Hello 
> winInitMultiWindowWM - Calling pthread_mutex_lock () 
> winMultiWindowXMsgProc - Calling pthread_mutex_lock () MIT-SHM
> extension disabled due to lack of kernel support XFree86-Bigfont
> extension local-client optimization disabled due to lack of shared
> memory support in the kernel (--) Setting autorepeat to delay=500,
> rate=31 (--) winConfigKeyboard - Layout: "0409" (0409) (--)
> Using preset keyboard for "English (USA)" (409), type "4" (--) 8
> mouse buttons found Could not init font path element
> /usr/X11R6/lib/X11/fonts/CID/, removing from list!
> 
> Fatal server error: could not open default font 'fixed'
> 
> -- Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple 
> Problem reports:   http://cygwin.com/problems.html Documentation:
> http://x.cygwin.com/docs/ FAQ:
> http://x.cygwin.com/docs/faq/
> 


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/



Re: Windows Vista

2008-08-24 Thread Monson Hayes
Not sure how to reply to a thread, but here are the details of what 
happens when I try to run

Cygwin/X.  First, I would like to comment that the following was suggested:

Be sure to set up $DISPLAY in your .bashrc:

   export DISPLAY=localhost:0.0

What is interesting, is in my installation I cannot find a .bashrc file, 
although I did find one in my

Windows XP installation.

I am told to look at the XWin.log file on my computer running Windows 
Vista when I get the

following fatal error:

"A fatal error has occurred and Cygwin/X will now exit
Releast 6.8.99.901-4
   XWin was started with the following command llin

   /usr/X11R6/bin/XWin -multiwindow - clipboard -silent-dup-error

The XWin.log file is:

(WW) /tmp mounted int textmode
_XSERVTransmkdir: ERROR: euid != 0,directory /tmp/.X11-unix will not be 
created.

(II) XF86Config is not supported
(II) See http://x.cygwin.com/docs/faq/cygwin-x-faq.html for more information
winAdjustVideoModeShadowGDI - Using Windows display depth of 32 bits per 
pixel
winAllocateFBShadowGDI - Creating DIB with width: 1680 height: 1050 
depth: 32
winInitVisualsShadowGDI - Masks 00ff ff00 00ff BPRGB 8 d 24 
bpp 32

null screen fn ReparentWindow
null screen fn RestackWindow
InitQueue - Calling pthread_mutex_init
InitQueue - pthread_mutex_init returned
InitQueue - Calling pthread_cond_init
InitQueue - pthread_cond_init returned
winInitMultiWindowWM - Hello
winMultiWindowXMsgProc - Hello
winInitMultiWindowWM - Calling pthread_mutex_lock ()
winMultiWindowXMsgProc - Calling pthread_mutex_lock ()
MIT-SHM extension disabled due to lack of kernel support
XFree86-Bigfont extension local-client optimization disabled due to lack 
of shared memory support in the kernel

(--) Setting autorepeat to delay=500, rate=31
(--) winConfigKeyboard - Layout: "0409" (0409)
(--) Using preset keyboard for "English (USA)" (409), type "4"
(--) 8 mouse buttons found
Could not init font path element /usr/X11R6/lib/X11/fonts/CID/, removing 
from list!


Fatal server error:
could not open default font 'fixed'

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/



Re: Windows Vista

2008-08-23 Thread Brian Wisti
I still haven't been able to get Cygwin/X working under Vista yet. I
was able to use XLaunch and fire off X applications from the cygwin
shell.

http://www.straightrunning.com/XmingNotes/

Be sure to set up $DISPLAY in your .bashrc:

export DISPLAY=localhost:0.0

I'd love to know if there's a better way, though.

Kind Regards,

Brian Wisti

On Sat, Aug 23, 2008 at 7:26 PM, Monson Hayes <[EMAIL PROTECTED]> wrote:
> I have tried to install Cygwin/X under Windows Vista, and get fatal errors
> when trying to run Cygwin/X.
> Has anyone been successful and, if so, is there documentation on how to get
> Cygwin running under Vista?
>
> --
> Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
> Problem reports:   http://cygwin.com/problems.html
> Documentation: http://x.cygwin.com/docs/
> FAQ:   http://x.cygwin.com/docs/faq/
>
>

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/



Re: Windows Vista

2007-04-24 Thread Scott Fordin

Brian Dessent wrote:

Scott Fordin wrote:

Also make sure that you run the Cygwin setup as Administrator.


Eh?  I just installed on Vista yesterday and all I had to do was click
on setup.exe.  Vista asked to run it as administrator since the
executable is named setup.exe.   I didn't have to do anything special.


Dunno. It was the only I way I could get it to work, and I was
following advice I read elsewhere. In any case, it did work when
I ran it as Administrator. Are there any downsides to doing it
this way?

Scott


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/



Re: Windows Vista

2007-04-23 Thread Brian Dessent
Scott Fordin wrote:

> > No.  The error you got is unlikely to be as a result of Vista.  Try a
> > different mirror.
> 
> Also make sure that you run the Cygwin setup as Administrator. This
> doesn't just mean that your user account has Administrator rights;
> you have to right-click the Cygwin setup.exe and then choose "Run
> as Administrator" from the pop-up menu.

Eh?  I just installed on Vista yesterday and all I had to do was click
on setup.exe.  Vista asked to run it as administrator since the
executable is named setup.exe.   I didn't have to do anything special.

BTW this is not X-specific so you should probably ask on the main list
unless you have X related issues.

Brian

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/



Re: Windows Vista

2007-04-23 Thread Scott Fordin

Larry Hall (Cygwin X) wrote:

Mariana Silva wrote:

Hello

I am trying to install cygwin/X in Windows Vista and I get a message
saying that the installation could not be completed. Is there a new version
of cygwin/X for this operational system?


No.  The error you got is unlikely to be as a result of Vista.  Try a
different mirror.


Also make sure that you run the Cygwin setup as Administrator. This
doesn't just mean that your user account has Administrator rights;
you have to right-click the Cygwin setup.exe and then choose "Run
as Administrator" from the pop-up menu.

FWIW, I have both Cygwin and Xming on my Vista notebook. I use Cygwin
when I need a real shell environment on my Vista machine. I use Xming
and PuTTY when I just need an X server and an ssh session on a remote
Solaris or Linux box. Both work great!

Hope this helps,

Scott

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/



Re: Windows Vista

2007-04-23 Thread Larry Hall (Cygwin X)
Mariana Silva wrote:
> Hello
> 
> I am trying to install cygwin/X in Windows Vista and I get a message
> saying that the installation could not be completed. Is there a new version
> of cygwin/X for this operational system?


No.  The error you got is unlikely to be as a result of Vista.  Try a
different mirror.



-- 
Larry Hall  http://www.rfk.com
RFK Partners, Inc.  (508) 893-9779 - RFK Office
216 Dalton Rd.  (508) 893-9889 - FAX
Holliston, MA 01746

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://x.cygwin.com/docs/
FAQ:   http://x.cygwin.com/docs/faq/