#### Release 4.3.0-37

Released: 2004-01-11 0215 EST
Download source: no longer distributed
Changes:
InitOutput.c, win.h, winclipboardthread.c, winwndproc.c - Remove the winDeinitClipboard function since it is no longer needed due to the OsVendorReset function. (Harold L Hunt II) winclipboardxevents.c/winClipboardFlushXEvents - Move variable declarations into the event loop so that they are reinitialized for each event that is processed. Remove all calls to pthread_exit and replace them with an abort section in each event that frees allocated resources and sends a SelectionNotify message when the SelectionRequest event is being aborted. Make sure that CloseClipboard will always be called if OpenClipboard has been called. Review the entire function to make sure that the responses to failures are appropriate. The result of this audit is that the clipboard code should not shut down as often from encountering minor errors. (Harold L Hunt II)

#### Release 4.3.0-36

Released: 2004-01-10 2245 EST
Download source: no longer distributed
Changes:
winclipboardxevents.c/winClipboardFlushXEvents/SelectionRequest - When aborting because neither CF_TEXT nor CF_UNICODETEXT are available from the clipboard, be sure to do so before calling OpenClipboard so that we don't have to be careful to call CloseClipboard when aborting. This should fix problems with other Win32 apps not being able to use the clipboard until something was selected in X11. (Harold L Hunt II)

#### Release 4.3.0-35

Released: 2004-01-10 2015 EST
Download source: no longer distributed
Changes:
winclipboardwrappers.c/winProcSetSelectionOwner - Remember to abort if stuff->window == None and we did not previously abort. This fixes crashes in some cases when the X11 selection is being disowned by another X Client. (Harold L Hunt II) winclipboardwndproc.c/winClipboardWindowProc/WM_DRAWCLIPBOARD - Do not take ownership of the X11 selections when something other than CF_TEXT or CF_UNICODETEXT has been copied into the Win32 clipboard. (Harold L Hunt II) winclipboardxevents.c/winClipboardFlushXEvents - Make sure that CF_TEXT and CF_UNICODETEXT are available from the clipboard before request their contents. This some fix some weird behavior and possible crashes. (Harold L Hunt II)

#### Release 4.3.0-34

Released: 2004-01-10 0200 EST
Download source: no longer distributed
Changes:
winwndproc.c/winWindowProc/WM_DISPLAYCHANGE - Save value of SM_C*VIRTUALSCREEN when fMultipleMonitors is true, instead of SM_C*SCREEN. (Harold L Hunt II) winclipboardwrappers.c/winProcEstablishConnection - Change delay in starting clipboard client from the 3rd call to the 4th call when using Xdmcp. Should fix the problem reported by Andrew Braverman; if not, I'll have to make a much more robust system for starting the clipboard client when using Xdmcp. (Harold L Hunt II) winclipboardwrappers.c/winProcSetSelectionOwner - Always advertise CF_TEXT clipboard format, optionally advertise CF_UNICODETEXT format. (Harold L Hunt II) winclipboardwndproc.c/winClipboardWindowProc/WM_RENDERFORMAT - If wParam is CF_UNICODETEXT, pass TRUE for Unicode support flag (regardless of fUnicodeSupport value) when calling winClipboardFlushXEvents. (Harold L Hunt II) winclipboardwndproc.c/winClipboardWindowProc/WM_DESTROYCLIPBOARD - Add new handling for this message; we are supposed to process this message for delayed rendering support. (Harold L Hunt II) General Clipboard - Restructure the clipboard system to run a single thread, regardless of the number of screens created in the current process; the reason for this is that X selections are per-display, not per-screen, thus there is no reason to have one thread per screen for managing the clipboard integration. Changing from per-screen to one thread greatly simplified the clipboard handling code and reduced the likelihood of errors due to interaction between multiple clipboard client threads. (Harold L Hunt II) winclipboardwrappers.c/winProcSetSelectionOwner - Track whether the PRIMARY and CLIPBOARD selections are owned and if they are transitioning from owned to not owned. When one of PRIMARY or CLIPBOARD is still owned the Win32 clipboard is not disowned; if both PRIMARY and CLIPBOARD are not owned and a transition from one being owned to being disowned is detected, then the Win32 clipboard is disowned. The user-level change is that you can select text in certain X11 apps (which usually sets both the PRIMARY and CLIPBOARD selections), click elsewhere to unselect the text (frees ownership of one of the selections but not the other) and still paste the text in Win32. The previous behavior would not allow you to paste the text in Win32 if the selection was no longer highlighted. (Harold L Hunt II) winclipboardwndproc.c/winClipboardWindowProc/WM_DRAWCLIPBOARD - We cannot bail out when NULL == GetClipboardOwner() because some applications deal with the clipboard in a manner that causes the clipboard owner to be NULL when they are in fact taking ownership. One example of this is the Win32 native compile of emacs. Without this fix, text could not be copied from the Win32 compile of emacs and pasted within Cygwin/X. (Harold L Hunt II) InitOutput.c - Remember to delete the functions that were moved to the new file called winprocarg.c. (Harold L Hunt II)

#### Release 4.3.0-33

Released: 2004-01-07 2315 EST
Download source: no longer distributed
Changes:
General - If you use the diff above, note that the Imakefile was missing from previous tarballs, so this diff includes the whole Imakefile. I have updated my source packaging script so that this does not happen again. Also, the source code in this release has already been committed to the xorg repository on freedesktop.org's CVS. (Harold L Hunt II) winauth.c - New File - Move winGenerateAuthorization into this new file. This function generates a cookie to be used by the clipboard client for authorization when using Xdmcp. (Harold L Hunt II) winglobals.c - New File - Start moving global variables into this file. (Harold L Hunt II) winclipboardwrappers.c - New File - Move all clipboard wrappers of ProcVector and InitialVector functions into this file. (Harold L Hunt II) winprocarg.c - New File - Move winInitializeDefaultScreens and ddxProcessArgument from InitOutput.c into this file. The same will be done eventually for other functions in InitOutput.c. (Harold L Hunt II) win.h, General - Get started on removing "extern" declarations from win.h by including explicit references to extern symbols in the source files that use those symbols. The long term goal is to start breaking up the monolithic win.h header file. (Harold L Hunt II) Xserver/dix/dispatch.c/Dispatch() - Add hook to OsVendorReset function that can be optionally defined in the DDX layer when DDXOSRESET is defined. (Harold L Hunt II) InitOutput.c/OsVendorReset() - New Function - Send a message to the clipboard client telling it to shutdown, then wait for the clipboard client thread to exit before proceeding. This allows us to cleanly shutdown the clipboard client. Incidentally, I noticed that the previous code would spawn *additional* clipboard client threads when the X Server was reset; this was happening because we trapped IO errors and attempted to reconnect when they happened. There was no code that told a clipboard client thread to exit when the server was being reset so that it could be replaced by a new clipboard client thread (which was happening correctly). This should lead to greater stabilility across X Server resets, though I did discover that this version and previous versions where shutting down after two or three resets without any error message being logged nor exception being thrown. That problem will be looked into later. (Harold L Hunt II) winclipboardinit.c, winclipboardthread.c, winclipboardxevents.c, winclipboardwndproc.c - Fix problems getting killed by Xdmcp code and remote XDM/KDM/GDM client on startup. Fix problems not being authorized to connect when using Xdmcp by calling XSetAuthorization and passing it our cookie that was created earlier; this removes the need to save the cookie to a .Xauthority file. Watch the CLIPBOARD selection in addition to the PRIMARY selection and track which was changed within X last so that we know which one we should paste within Win32. Fix crashes when the server resets (as explained above, it still exits after one or two resets, for an unknown reason). The improved clipboard code should now be good to go. (Harold L Hunt II) winmultiwindowwm.c - Clean up the startup of the two multi-window threads. Create separate error and IO error handlers for the XMsgProc thread since it was using the same IO error handler as another thread and would try to longjmp into the other thread if it received an IO error, which was likely causing some crashes. The multi-window code needs additional work to confirm that it properly shuts down and exits both threads; something similar to the clipboard shutdown message in OsVendorReset will be needed. (Harold L Hunt II) winclipboardxevents.c - Find and fix a last minute bug that caused Unicode clipboard translations to be broken. (Kensuke Matsuzaki, Harold L Hunt II)

#### Release 4.3.0-32

Released: 2004-01-05 1715 EST
Download source: no longer distributed
Changes:
win.h/WIN_CLIPBOARD_AUTH_SUPPORT - Disable the new Xauth support for the clipboard integration manager with a build-time flag. Be sure to delete ~/.Xauthority if you have one; X Client connections may be prevented if you do not delete this file. (Harold L Hunt II) InitInput.c/InitInput - Only wrap ProcVector[X_SetSelectionOwner] when serverGeneration is 1, which prevents multiple wrapping of the function when the server resets (the ProcVector table is not re-initialized upon X Server reset). (Harold L Hunt II) InitInput.c/winProcSetSelectionOwner - Use ((DrawablePtr) pWindow)->id instead of client->lastDrawableID for determining the ID of the window that the selection is being owned by. (Harold L Hunt II) InitInput.c/winProcSetSelectionOwner - Detect when pWindow is None, in which case the selection is being unowned in X11; add code to release ownership of the Win32 clipboard if we currently own it. (Harold L Hunt II) InitInput.c/winProcSetSelectionOwner - Abort if IsWindow fails for the clipboard manager Win32 window handle; this may prevent problems when the X Server resets. (Harold L Hunt II) winclipboardwndproc.c/winClipboardWindowProc/WM_DRAWCLIPBOARD - Don't call XSetSelectionOwner when GetClipboardOwner returns NULL, since this means that the Win32 clipboard is unowned; there are many reasons why the Win32 clipboard may be unowned, one of which is that we release ownership of it when the X11 selection is unowned (see above item). (Harold L Hunt II)

#### Release 4.3.0-31

Released: 2004-01-05 0105 EST
Download source: no longer distributed
Changes:
General - Everything up to the last three entries describes the new clipboard handling system that does not steal ownership of the X11 selection each time that something is selected; this seems to work fine, but it needs to be tested. The last three entries describe my nearly complete attempt at generating a MIT-MAGIC-COOKIE-1, adding it to the list of cookies that the X Server recognizes, and using it when the clipboard client tries to connect during an XDMCP connection. This authentication approach should work, but I need a break from trying to figure out which of the function calls has a minor error in its parameters; thus, it does not currently work. However, feel free to examine the source code and let me know if any of my calls to GenerateAuthorization, AddResource, or XauWriteAuth are incorrect. I would really like to get this automatic authorization working as soon as possible. Until then I will mark this release (and all releases based upon it) as 'test'. InitInput.c - Add a function, winProcSetSelectionOwner, and wrap the generic function ProcVector[X_SetSelectionOwner] with it. This allows us to get a notification each time the selection (clipboard) owner changes. Call SetClipboardData (foo, NULL) so that the WM_RENDERFORMAT message will be posted when a Win32 app requests the clipboard contents. (Harold L Hunt II, Alexander Gottwald) winclipboardxevents.c/winClipboardFlushXEvents/SelectionNotify - No longer steal ownership of the selection each time it changes in X11. We can do this because we have notification when SetSelectionOwner is called (see above). (Harold L Hunt II) winclipboardxevents.c/winClipboardFlushXEvents/SelectionClear - Remove handling, it is no longer needed; it used to request the contents of the selection that we lost ownership of. (Harold L Hunt II) winclipboardwndproc.c/winClipboardWindowProc/WM_CREATE,WM_DESTROY - Add information to be used on each call to a window property. (Harold L Hunt II) winclipboardwndproc.c/winClipboardWindowProc/WM_CREATE,WM_DESTROY,WM_CHANGECBCHAIN,WM_DRAWCLIPBOARD - Add ourselves to the clipboard viewer chain so that we receive notification when the clipboard contents are changed by a Win32 application. Our normal response to this is to call XSetSelectionOwner, but we specifically do nothing if we currently own the Win32 clipboard. (Harold L Hunt II) winclipboardwndproc.c/winClipboardWindowProc/WM_RENDERFORMAT,WM_RENDERALLFORMATS - Request the contents of the X11 selection. Use XPeekIfEvent to wait until the response is added to our event queue (this could probably lead to a dead-lock of a client exists before responding), then call winClipboardFlushXEvents to handle the SelectionNotify event. UTF8 and CompoundText targets require that we call XConvertSelection from the SelectionNotify event, which will cause another SelectionNotify event to be fired; be careful to check for this and do the XPeekIfEvent/winClipboardFlushXEvents thing again if this is the case (this is untested because I did not see any UTF8 or CompoundText targets that needed conversion). Copy the returned contents to the Win32 clipboard with SetClipboardData (). (Harold L Hunt II) winscrinit.c/winFinishScreenInitFB - Generate a MIT-MAGIC-COOKIE-1 cookie and add it to the server's list of cookies. (Harold L Hunt II) winclipboardthread.c/winClipboardSaveXauthData - Add the generated MIT-MAGIC-COOKIE-1 cookie to the Xauthority file. Beware that this is hard-coded to 127.0.0.1:0 and that the entry is not cleaned up upon exit; this will force the host-based access to be disabled in some cases and could cause problems starting X Clients until this is fixed. (Harold L Hunt II) xc/programs/Xserver/Imakefile - Add $(OS) to the XWINLIBS just after libXwin.a is included, which allows us to call unreferenced functions in libXau.a, such as XauWriteAuth. (Harold L Hunt II)

#### Release 4.3.0-30

Released: 2003-12-31 1855 EST
Download source: no longer distributed
Changes:
xc/programs/XServer/os/access.c - Fix a typo that was causing localhost connections to be sent in xdmcp request packets. On Darwin this connection was even advertized first, causing troubles later. (Matthieu Herrb) http://cvsweb.xfree86.org/cvsweb/xc/programs/Xserver/os/access.c.diff?r1=3.50&r2=3.51

#### Release 4.3.0-29

Released: 2003-12-24 1624 EST
Download source: no longer distributed
Changes:
winkeybd.c/winIsFakeCtrl_L - Call Sleep (0) if the first call to PeekMessage returns nothing. TweakUI occasionally causes the Alt_R press/release to not be in the message queue at the time that we receive the fake Ctrl_L press/release. Calling Sleep (0) gives up the rest of our time slice to other apps that need it, which causes the Alt_R message to show up on our queue. We can then call PeekMessage again and check if the Alt_R is there or not. If it is not there, then we assume that we have a real Ctrl_L press, if it is there, then we discard the fake Ctrl_L as usual. I tested this with the US-International layout and it seemed to work fine. I originally coded this fix with a short "keytest" program and was able to confirm that the fix works there as well. (Harold L Hunt II) win.h, winkeybd.c, winkeybd.h, winwndproc.c - Remove dead code that was wrapped with #if WIN_NEW_KEYBOARD_SUPPORT. (Harold L Hunt II)

#### Release 4.3.0-28

Released: 2003-12-23 1125 EST
Download source: no longer distributed
Changes:
General - Rebrand Cygwin/XFree86 as Cygwin/X since we aren't really a port of XFree86's DDX to Windows; rather, we are a port of the X Window System to Windows. (Harold L Hunt II)

#### Release 4.3.0-27

Released: 2003-12-23 0035 EST
Download source: no longer distributed
Changes:
wincreatewnd.c - Don't bring the top-level window to the top in Multi-Window and Rootless modes. (Kensuke Matsuzaki)

#### Release 4.3.0-26

Released: 2003-12-18 1015 EST
Download source: no longer distributed
Changes:
winkeybd.c - Properly save and clear the pointer to the internal mode key state data when the keyboard is initialized, enabled, and disabled. (Takuma Murakami)

#### Release 4.3.0-25

Released: 2003-11-24 0915 EST
Download source: no longer distributed
Changes:
winkeybd.c - Before setting the autorepeat defaults, check if XKB was not disabled and suppress the error message in the other case. (Alexander Gottwald) winconfig.c - Set xkb.disable even if no default keyboard is configured. (Takuma Murakami, Alexander Gottwald)

#### Release 4.3.0-24

Released: 2003-11-21 1425 EST
Download source: no longer distributed
Changes:
InitOutput.c/ddxProcessArgument () - Keep track of the -kb parameter. (Alexander Gottwald) winwndproc.c/winWindowProc () - Only discard the windows autorepeat messages if the XKB layer is not disabled. (Alexander Gottwald) winconfig.c - Query windows about its keyboard autorepeat rate and use this as default for the xserver. (Alexander Gottwald) winconfig.c - Changed log output for keyboard autodetection to use the probed-prefix instead of the default-prefix. (Alexander Gottwald)

#### Release 4.3.0-23

Released: 2003-11-17 2100 EST
Download source: no longer distributed
Changes:
General - Recompile all libraries and executables against fixed Xaw and Xt libraries. Enabled OS/2-style fix for VendorShell and vendorShellWidgetClass. (Harold L Hunt II) winkeybd.c/winKeybdProc () - Check xkbi pointer for NULL. Fixes crash when XKB was disabled with ``-kb''. (Alexander Gottwald) winconfig.c/winConfigKeyboard () - Read the AutoRepeat option from the configfile. (Alexander Gottwald) winkeybd.c/winKeybdProc () - Initialize the XKB input layer with the AutoRepeat options from the configfile. (Alexander Gottwald)

#### Release 4.3.0-22

Released: 2003-11-09 1622 EST
Download source: no longer distributed
Changes:
win.h, winkeybd.c, winmultiwindowwndproc.c, winwndproc.c - Remove winStoreModeKeyStates () function and stop storing mode key state within the hw/xwin layer. Instead, query the internal X Server mode key state, when we know that no key press/release events are pending, and send key press/release events to get that state in sync with the Windows mode key states. This removes the possibility that the hw/xwin and internal X Server mode key state vectors would get out of sync. This is also a general cleanup that utilizes more existing code and removes some Cygwin-specific code. (Takuma Murakami) winwndproc.c - Catch WM_ENDSESSION message and perform clean shutdown. (Takuma Murakami) winwndproc.c - WM_*KEYDOWN - Discard key presses generated from Windows auto-repeat (these sorts of auto-repeats are handled by X). (Takuma Murakami) winmouse.c - Remap mouse buttons here when XFree86Server and XINPUT are defined, since this combination of flags prevents a lower layer from performing such remapping. The end result is that remapping mouse buttons works for the first time. (Takuma Murakami) winconfig.c - Load the US keyboard layout for Japanese keyboards. This ensures that WM_KEYUP messages are sent for the Caps Lock key. (Takuma Murakami, Kensuke Matsuzaki) win.h, winengine.c, winmultiwindowwindow.c, winmultiwindowwm.c, winpfbdd.c, winshaddd.c, winshadddnl.c, winshadgdi.c, winwindow.h - Add an engine-specific function that is called after a Windows-window is created in -multiwindow mode. This is a start for adding DirectDraw support to -multiwindow mode. However, I got a little confused here and thought that one primary surface would need to be created per window, which is not correct. There will be one primary surface with a clip list that causes blits to stay within the region of all of our visible windows. In any case, this is a step in the right direction. There code is currently disabled since the engine setting code only allows the GDI engine when -multiwindow is being used. (Harold L Hunt II)

#### Release 4.3.0-21

Released: 2003-10-28 1355 EDT
Changes:
General - Recompile all libraries and executables against stand-alone freetype2 and fontconfig packages. (Harold L Hunt II) General - Cygwin now has strl{cat,cpy}(), so #define HasStrlcat as YES in xc/config/cf/cygwin.cf and rebuild all apps and libraries. (Matthieu Herrb)

#### Release 4.3.0-20

Released: 2003-10-17 1340 EDT
Download source: no longer distributed
Changes:
Clipboard Support - Enabled copying and pasting of non-ascii characters even when Windows does not support Unicode (i.e. Windows 95/98/Me). (Kensuke Matsuzaki) Clipboard Support - Add ``-nounicodeclipboard'' command-line parameter that instructs the clipboard support in XWin.exe to not use Unicode functions, even if Windows supports them. (Kensuke Matsuzaki) winconfig.c - Prevent JP layouts loaded for JP Windows with US keyboards. (Takuma Murakami) winscrinit.c - Bail if -rootless and -multiwindow flags both present. (Harold L Hunt II)

#### Release 4.3.0-18

Released: 2003-10-06 2120 EDT
Download source: no longer distributed
Changes:
winclipboardxevents.c - Fix crash when copying large amounts of data from an X application. The crash was caused because the encoding of the XTextProperty was INCR, which is an incremental transfer of large amounts of text. The problem isn't really fixed because copying or cutting large amounts of text now causes that text to be lost without warning, rather than copied to the clipboard. The real solution will be to implement the INCR protocol, which will follow in a few days. (Kensuke Matsuzaki, Harold L Hunt II)

#### Release 4.3.0-17

Released: 2003-10-05 1305 EDT
Download source: no longer distributed
Changes:
winwndproc.c - Ignore Win32 repeats for the VK_CAPITAL (Caps Lock) key. This may or may not help to keep the state of the Caps Lock key in X and Windows in sycnh; it all depends on whether we are receiving multiple VK_CAPITAL key press messages, or if we are receiving one key press message with a repeat count greater than 1. If this doesn't work then we may need to look at masking key press events for Lock keys that are already pressed in X. (Harold L Hunt II)

#### Release 4.3.0-16

Released: 2003-10-04 1735 EDT
Note: No Cygwin-specific changes this time. The only file changed was xc/programs/Xserver/os/WaitFor.c, which was merely synchronized with XFree86's CVS HEAD version.
Changes:
xc/programs/Xserver/os/WaitFor.c - Backport Ivan Pascal's final changes to timer processing (which was causing duplicate keystrokes in some situations).

#### Release 4.3.0-15

Released: 2003-10-03 2100 EDT
Download source: no longer distributed
Changes:
winconfig.c - Add another German keyboard layout. (Alexander Gottwald) winconfig.c - Setting the default layout for Japanese to jp (was jp106 before). (Alexander Gottwald) winconfig.c - Add a new default for Portuguese (Brazil, ABNT2). (Alexander Gottwald) winconfig.c - Print the layout number in hexadecimal instead of decimal. (Alexander Gottwald) winmultiwindowwndproc.c/winTopLevelWindowProc() - Add processing for WM_WINDOWPOSCHANGED to cause window to repaint when using TweakUI's focus-follows-mouse behavior. (Harold L Hunt II)

#### Release 4.3.0-14

Released: 2003-09-22 1550 EDT
Download source: no longer distributed
Changes:
winconfig.c - Add the Japanese keyboard layout to the list of defaults as jp106. (Alexander Gottwald)

#### Release 4.3.0-13

Released: 2003-09-21 0014 EDT
Download source: no longer distributed
Changes:
Merge NativeGDI development branch. The NativeGDI engine is now accessible via the "-engine 16" command-line parameter. Note that the byte order for 1-bit bitmaps is only configurable at compile time, which causes the output to be totally messed up. Although, you can at least examine how the engine currently works. (Alan Hourihane) Display the argument to the -query option in the window title. (Alexander Gottwald) winprefslex.l - Remove use_unused_functions(), which was only used to force two functions to be imported, thus eliminating a compiler warning. This is no longer needed with the newest test version of flex. (Earle F Philhower III) cygwin.cf - Define HasExpat as YES. This adds a dependency on Cygwin's expat lib, but it removes the distribution of an out of date version of expat that was included with the XFree86 source code. (Gerrit P. Haase, Harold L Hunt II, Alexander Gottwald) Fix the occasional repeating of keystrokes in the xkb layer. This problem has been present in XFree86 for years, but it was more apparent on Cygwin/X. This patch is not yet in the XFree86 CVS tree, so any bugs caused by this patch will need to be reported to XFree86. See the following email for a description of how the patch works XFree86 patch email. (Ivan Pascal) General - Add runtime detection for the Cygwin IPC Daemon. This allows SHM (shared memory) support when the IPC Daemon is running. SHM support is automatically disabled, with no adverse effect, when the IPC Daemon is not running. There is now a dependency on the cygipc package, but no additional installation steps are required, unless you want SHM support; in which case you need to run ipc-daemon2 (See the cygipc documentation for more details). (Ralf Habacker, Harold L Hunt II) cygwin.cf - Ditch "-DNO_ALLOCA" and replace with "-DINCLUDE_ALLOCA_H" for AllocateLocalDefines. (Nicholas Wourms) cygwin.cf - Ditch "-DUSE_XWCHAR_STRING -DUSE_XMBTOWC" and use "-DHAS_WCHAR_H -DHAS_WCTYPE_H -DHAS_ISW_FUNCS -DNO_WIDEC_H" for XawI18nDefines. (Nicholas Wourms) General - Recompile all libraries and executables for run-time enabled shared memory support (SHM). (Harold L Hunt II) General - Recompile all libraries and executables for Cygwin 1.5.3+. (Harold L Hunt II) X11.tmpl, cygwin.rules - Fix some warnings about undefined symbols during cross compilation. (Harold L Hunt II)