Neszt,

        "freeglut" does not capture the Control, Shift, or Alt key press and release events when they happen.  When the application is in a callback from "freeglut" it can call "glutGetModifiers" which will return a bitmap with the bits set or unset:

        GLUT_ACTIVE_SHIFT
        GLUT_ACTIVE_CTRL
        GLUT_ACTIVE_ALT

A typical application uses code like

if ( glutGetModifiers() & GLUT_ACTIVE_SHIFT )
{
  /* SHIFT key pressed */
}
else
{
  /* SHIFT key not pressed */
}

For system-specific code you can look in "freeglut_main.c" around line 495 for X11 and around line 1086 for Windows.

        I hope this helps.

John F. Fay
john.fay@eglin.af.mil
850-729-6330
-----Original Message-----
From: freeglut-developer-admin@lists.sourceforge.net [mailto:freeglut-developer-admin@lists.sourceforge.net] On Behalf Of Neszt Tibor

Sent: Tuesday, December 28, 2004 3:48 PM
To: freeglut-developer@lists.sourceforge.net
Subject: [Freeglut-developer] spec keys

Hello!

How can I catch the shift (or ctrl) key event in freeglut?


Thanks,
  Neszt Tibor


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://productguide.itmanagersjournal.com/
_______________________________________________
Freeglut-developer mailing list
Freeglut-developer@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freeglut-developer