* TextControl.cs: Remove RecalAlignments call, that was some
[mono.git] / mcs / class / Managed.Windows.Forms / System.Windows.Forms / ChangeLog
index d1aa75928ccfa5c6dcc2dfd49bcdb3f33990a806..db4afbefc01d1056390e93474dc4c24f9789fda2 100644 (file)
@@ -1,3 +1,489 @@
+2007-02-20  Jackson Harper  <jackson@ximian.com>
+
+       * TextControl.cs: Remove RecalAlignments call, that was some
+       debugging leftovers.
+       - Don't use the line indent when we shouldn't.
+       * RichTextBox.cs: Add support for paragraph left indents.
+
+2007-02-20  Rolf Bjarne Kvinge  <RKvinge@novell.com>
+
+       * Control.cs: Fix BeginInvoke signature for 2.0 profile.
+       Seems like the class status pages doesn't catch params differences.
+
+2007-02-19  Gert Driesen  <drieseng@users.sourceforge.net>
+
+       * ComboBox.cs: Removed extra tabs. Changes spaces to tabs.
+
+2007-02-19  Gert Driesen  <drieseng@users.sourceforge.net>
+
+       * ComboBox.cs: Setting Text should have no effect if item text of
+       selected item exactly matches value. First lookup text using
+       case-sensitive comparison, and fallback to case-insensitive comparison.
+       FindString(Exact) returns -1 if search string is null. On 2.0 profile, 
+       allow startIndex to be last index. Changed ArgumentOutOfRangeException
+       paramname to match MS. Restart from first item if string is not found
+       after startIndex. Fixed paramname of ArgumentNullException that is
+       thrown for null value in ObjectCollection.Contains.
+
+2007-02-19  Everaldo Canuto  <everaldo@simios.org>
+
+       * XplatUIStructs.cs: WM_XXX UISTATE elements uncommented.
+
+2007-02-19  Rolf Bjarne Kvinge <RKvinge@novell.com> 
+
+       * ListControl.cs: In SelectedValue use value.Equals to compare for
+       equality instead of ==, otherwise it will fail for strings.
+       Fixes #80794.
+
+2007-02-19  Rolf Bjarne Kvinge <RKvinge@novell.com> 
+       
+       * ComboBox.cs: Switch the order to ShowSelection and ActivateCaret,
+       since the caret won't show up unless ShowSelection is true. 
+       Fixes #80795.
+
+2007-02-19  Rolf Bjarne Kvinge <RKvinge@novell.com> 
+
+       * Application.cs: When disabling all forms but the main form, do not
+         disable any descendants of the main form (such as mdi children or
+         other parented forms). Fixes #80822 on Windows.
+       * Form.cs: If we have a parent, set the WS_CHILD style.
+       * Control.cs: Update the window styles if the control whose parent has
+         changed is a form (the WS_CHILD style has to be switched).
+
+2007-02-19  Everaldo Canuto  <everaldo@simios.org>
+
+       * XplatUIStructs.cs: MsgUIState structure added.
+
+2007-02-18  Gert Driesen  <drieseng@users.sourceforge.net>
+
+       * FileDialog.cs: Removed need for separate fileName field. On 2.0
+       profile, do not check filename(s) for illegal character if filename(s)
+       were set non-interactively but always check on 1.0 profile. Fixed NRE
+        in DefaultExt and only strip off first leading dot. Improve exception
+       message when invalid Filter is set. Do not ignore InitialDirectory if
+       it does no exist. Store specified Title, and if empty use default
+       title (depending on type of dialog). Added an internal DialogTitle 
+       property for retrieving dialog title. Fixed logic of displayed dir to
+       more closely match MS. Avoid setting ComboBox.Text to a zero-length 
+       string as its buggy.
+       * OpenFileDialog.cs: In OpenFile, throw ArgumentNullException if
+       FileName is a zero-length string (it can never be null). Override 
+       DialogTitle property to set default title of dialog box.
+       * SaveFileDialog.cs: Override DialogTitle property to set default
+       title of dialog box.
+
+2007-02-18  Gert Driesen  <drieseng@users.sourceforge.net>
+
+       * FileDialog.cs: Modify default text of filename and filetype labels
+       to match that of MS. Reset do_not_call_OnSelectedIndexChanged...
+       after we've updated the SelectedIndex. Fixes part of bug #80887.
+       * SaveFileDialog.cs: Set text of filetype label.
+
+2007-02-16  Carlos Alberto Cortez <calberto.cortez@gmail.com>
+
+       * LabelEditEventArgs.cs: New internal SetLabel method, to set the
+       label field. Needed by latest Jackson's fixes for ListView.
+
+2007-02-16  Andreia Gaita  <avidigal@novell.com>
+
+       * PrintPreviewControl/PrintPreviewDialog: Properly dispose of 
+       print preview images.
+
+2007-02-16  Jackson Harper  <jackson@ximian.com>
+
+       * ListView.cs: Make AfterLabelEdit work correctly.
+       * FileDialog.cs: After changing the name of the folder, we have to
+       make sure that it is created, or that we pop up an error because
+       it already exists.
+
+2007-02-16  Jackson Harper  <jackson@ximian.com>
+
+       * X11Dnd.cs: Implement aliases on mime handlers, so things like
+       System.String are mapped to text.
+       - Handle dataobjects, getting all the possible formats out of them
+       - We dont need the drag event args before we give feedback. This
+       allows feedback cursors to be immediate before selections have
+       been converted.
+
+2007-02-16  Jackson Harper  <jackson@ximian.com>
+
+       * TextBoxBase.cs: Modified the method for inserting images to
+       taking a line and position instead of tag and position.
+       * RichTextBox.cs: Handle PngBlip data by inserting the png image
+       into the RTF file.
+       * TextControl.cs: Allow images to be inserted as the first tag of
+       a line.
+       - Fix some off by one issues when we assume the first tag is a
+       text tag, not an image tag.
+
+2007-02-15  Carlos Alberto Cortez <calberto.cortez@gmail.com>
+
+       * ListView.cs: Set focus to ListView when ItemControl gets a
+       WM_RBUTTONDOWN message, to mimic .Net behaviour. 
+       Fixes part of #80467.
+
+2007-02-15  Rolf Bjarne Kvinge <RKvinge@novell.com> 
+
+       * DateTimePicker.cs: Call RecreateHandle if the Format changes and
+         validate Text input (if null or empty string reset Value to default
+         value). Fixes #80830.
+
+2007-02-14  Carlos Alberto Cortez <calberto.cortez@gmail.com>
+
+       * ListView.cs: Set owner as null for columns and items when
+       Dispose is invoked. Fixes #80607.
+
+2007-02-14  Jonathan Pobst  <monkey@jpobst.com>
+
+       * ToolStrip.cs: Allow LayoutStyle.Flow, make sure to call OnOpening when
+       showing DropDowns, don't show a Grip when doing Flow layout.
+       [This fixes the toolbox in PDN 2.72.]
+       * ToolStripItem.cs: Add Anchor property and some internal properties to
+       reduces needed changes to FlowLayout.
+       * ToolStripOverflow.cs: Remove unused variable.
+       * ToolStripSplitStackLayout.cs: If a ToolStripItem isn't visible, don't
+       use it in the layout calculations.
+
+2007-02-13  Everaldo Canuto  <everaldo@simios.org>
+
+       * ToolTip.cs: Add HotkeyPrefix.Hide to MeasureString format, it fix an issue
+       reported in #79640.
+       
+       * ThemeWin32Classic.cs: Uses format for MeasureString in ToolTipSize to fiz
+       size calculation.
+
+2007-02-13  Everaldo Canuto  <everaldo@simios.org>
+
+       * ToolBar.cs, ToolBarButton.cs: Revert and remove HotkeyPrefix from 
+       MeasureString format, it can make button very large in some cases, it is
+       strange but is what win32 do.
+
+2007-02-13  Everaldo Canuto  <everaldo@simios.org>
+
+       * ToolBar.cs, ToolBarButton.cs: Uses format in MeasureString to fix string 
+       size calculation.
+
+       * ThemeWin32Classic.cs: Set HotkeyPrefix in toolbar text format to fix text
+       rendering, the value is based on MenuAccessKeysUnderlined.
+
+2007-02-13  Everaldo Canuto  <everaldo@simios.org>
+
+       * Theme.cs: Change MenuAccessKeysUnderlined to "true" that is value used
+       for most themes.
+       
+       * ThemeWin32Classic.cs: Override MenuAccessKeysUnderlined as false.
+       
+       * ThemeNice.cs, ThemeGtk.cs, ThemeClearlooks.cs: Remove always_draw_hotkeys
+       and use MenuAccessKeysUnderlined instead.
+
+2007-02-13  Andreia Gaita  <avidigal@novell.com>
+
+       * ContainerControl.cs: Focus fix for nunit treeview selection bug.
+       A selected control would not get a Focus call if:
+               - the default active control of the container is the same as
+                 the one that was selected
+               - we are switching from one container to another
+       Under these conditions, the container being selected already has
+       an active_control, which is the same as the one being activated, 
+       so set_ActiveControl would always return and not send the Focus
+       call. Fix to check if the currently active control of the container
+       is actually focused.
+
+2007-02-13  Jonathan Pobst  <monkey@jpobst.com>
+
+       * StatusStrip.cs: Implement the spring layout.
+       * ToolStripControlHost.cs: Make sure the hosted control's visibility
+       always matches the host.
+       * ToolStripItem.cs: Write a more accurate layout for TextBeforeImage
+       and TextAfterImage.
+
+2007-02-13  Andreia Gaita  <avidigal@novell.com>
+
+       * Control.cs: Code reorganization only.
+         - Reorganize the WndProc cases so that each case has it's own handling method, 
+         to help with the no-line-numbering stack traces.
+         - Formatting changes (it's vstudio's fault, really :p)
+
+2007-02-13  Rolf Bjarne Kvinge <RKvinge@novell.com> 
+
+       * MonthCalendar.cs: Switch to using Thread.CurrentCulture instead of
+         Thread.CurrentUICulture to match DateTimePicker's (and MS)
+         behaviour.
+
+2007-02-12  Jackson Harper  <jackson@ximian.com>
+
+       * RichTextBox.cs:
+       * TextBox.cs: By default we have a non multiline document
+       - use the multiline property instead of the internal variable
+       * TextBoxBase.cs: Treat multiline and non multiline the same in
+       most places.
+       - Use the documents multiline flag instead of tracking it ourself
+       * TextControl.cs: Attempt at getting multiline to match MS
+       behavior.  Lines now track an offset, which is either their X or Y
+       offset depending on whether or not we are in multiline mode.
+       - Update all the methods to understand that lines have an X value.
+       - Fix crash in Undo::Duplicate when empty lines are deleted.
+
+2007-02-12  Everaldo Canuto  <everaldo@simios.org>
+
+       * Label.cs: CalcPreferredHeight and CalcPreferredWidth methods removed and 
+       code moved to properties PreferredHeight and PreferredWidth. It solve the
+       all problems when preferred sizes must be recalculated. Fixes #80801.
+
+2007-02-12  Everaldo Canuto  <everaldo@simios.org>
+
+       * Label.cs: Fix CalcPreferredHeight for 2.0 that must return only
+       font height when compatible_text_rendering is false. Partially fix #80801.
+
+2007-02-09  Gert Driesen  <drieseng@users.sourceforge.net>
+
+       * Form.cs: Fixed typo in exception message. Fixes bug #80779.
+
+2007-02-09  Gert Driesen  <drieseng@users.sourceforge.net>
+
+       * Form.cs: Improved exception messages in ShowDialog.
+
+2007-02-09  Gert Driesen  <drieseng@users.sourceforge.net>
+
+       * PrintDialog.cs: On 1.0 profile, throw ArgumentException in RunDialog if
+       PrinterSettins has not been set. On 2.0 profile, initialize PrinterSettings
+       if not set. Fixes bug #80764. Avoid accessing current_settings field
+       directly.
+
+2007-02-08  Everaldo Canuto  <everaldo@simios.org>
+
+       * Theme.cs: An new property MenuAccessKeysUnderlined added with default value
+       false.
+
+       * SystemInformation.cs: An new property MenuAccessKeysUnderlined added, it is
+       public in 2.0 and for easy maintenance and dont break compatibility it is 
+       internal in 1.1.
+       
+2007-02-08  Jonathan Pobst  <monkey@jpobst.com>
+
+       * ToolStripItem.cs: Implement using images from ImageList.
+
+2007-02-08  Rolf Bjarne Kvinge <RKvinge@novell.com> 
+
+       * DateTimePicker.cs: Change default date-formatting culture from
+         CurrentThread.CurrentUICulture to CurrentThread.CurrentCulture,
+         seems to be the way MS does it.
+
+2007-02-08  Andreia Gaita  <avidigal@novell.com>
+
+       * PrintPreviewControl.cs: rewrite toolbar code to fix #80725. Correct 6-up image 
+       (the 6 was cut off on the right side)
+
+2007-02-08  Jonathan Pobst  <monkey@jpobst.com>
+
+       * Form.cs: Tell MenuStrips to close when the form is clicked.
+       * MenuStrip.cs, ToolStrip.cs, ToolStripControlHost.cs, 
+       ToolStripDropDown.cs, ToolStripDropDownItem.cs, ToolStripItem.cs,
+       ToolStripItemCollection.cs, ToolStripMenuItem.cs, ToolStripProfessionalRenderer.cs,
+       ToolStripSplitButton.cs, ToolStripSplitStackLayout.cs: Add 
+       support for Overflow, where items that do not fit are automatically
+       reparented to a drop down menu.
+       * ToolStripOverflow.cs, ToolStripOverflowButton.cs: Added.
+       Also: fixes bug #80747.
+
+2007-02-08  Rolf Bjarne Kvinge <RKvinge@novell.com> 
+
+       * ComboBox.cs: Remove warning (unused code).
+       * ScrollableControl.cs: Remove warning for 1.1 profile.
+
+2007-02-08  Rolf Bjarne Kvinge <RKvinge@novell.com> 
+
+       * Form.cs: Remove a warning.
+
+2007-02-08  Rolf Bjarne Kvinge <RKvinge@novell.com> 
+
+       * DateTimePicker.cs: Fixed a NRE if CustomFormat was null. Handles the
+         'g' specifier, not documented anywhere, but seems to always show up
+         as a single space (might have something to do with the DateTime 'g'
+         specifier, which is the era format, but since DateTimePicker can't
+         go earlier than 1753 it wouldn't matter) . Fixed quote handling,
+         won't crash if the format has an unmatched quote. Now shows
+         single-character formats correctly. Fixes #80744.
+
+2007-02-08  Jonathan Pobst  <monkey@jpobst.com>
+
+       * StatusStrip.cs: Stretch property needs to call base.Stretch,
+       not this.Stretch to fix stack overflow. [Fixes bug #80760]
+
+2007-02-07  Chris Toshok  <toshok@ximian.com>
+
+       * ThemeWin32Classic.cs (DrawButtonBase): don't clear to the
+       background color.  it overwrites the background image we've
+       already painted.  Fixes #80599.
+
+2007-02-07  Chris Toshok  <toshok@ximian.com>
+
+       * DataGrid.cs: return immediately from Edit() when there are no
+       columns.  Fixes #80662.
+
+2007-02-07  Chris Toshok  <toshok@ximian.com>
+
+       * MessageBox.cs: fix #80625.  don't always show the Help button in
+       2.0.  use the displayHelpButton parameter to determine if we
+       should show it. Also, make the internal show_help field private.
+
+2007-02-07  Chris Toshok  <toshok@ximian.com>
+
+       * Control.cs (SetVisibleCore): check in the proposed patch for
+       80604, and set is_visible before calling CreateControl.
+
+2007-02-07  Jonathan Pobst  <monkey@jpobst.com>
+
+       * ListView.cs: UseCompatibleStateImageBehavior setter changed from NIEX to 
+       MonoInternalNote.  This is added automagically by VS2005, so let's not crash
+       on it.
+
+2007-02-06  Everaldo Canuto  <everaldo@simios.org>
+
+       * MenuAPI.cs: hotkey_active internal field added, it is required because
+       we need to know when hotkeys must be draw, before this change a keystate
+       Navigating was used but we can have menu in navigating state without
+       hotkeys. Fixes #80694.
+       
+       * ThemeWin32Classic.cs: Only draw hot keys when hotkey_active is true.
+
+2007-02-06  Rolf Bjarne Kvinge <RKvinge@novell.com> 
+
+       * Control.cs: Handle WM_CAPTURECHANGED in 1.1 code as well, and change
+         corresponding events and methods to be internal for 1.1 profile and
+         public for 2.0 profile (required by SizeGrip).
+       * Form.cs: Use SizeGrip as a virtual SizeGrip (and don't add it to the
+         implicit control list). Don't set the size nor the location of the
+         SizeGrip anymore as it's not needed.
+       * SizeGrip.cs: Rewrote large parts, it now supports a virtual mode to
+         draw directly on the captured control (fixes #80656). Removed
+         ShowGrip (it wasn't used anywhere), redraw (always true), added
+         GetDefaultSize and GetDefaultRectangle to calculate defaults.
+       * ScrollableControl.cs: Make UpdateSIzeGripVisible internal so it can
+         be called from SizeGrip.
+
+2007-02-06  Rolf Bjarne Kvinge <RKvinge@novell.com> 
+
+       * Timer.cs: Throw ArgumentException if Interval <= 0.
+
+2007-02-05  Jackson Harper  <jackson@ximian.com>
+
+       * TreeView.cs: We need to check scrollbar visibility when window
+       visibility is updated, because non visible trees don't ever add
+       scrollbars.
+       * Cursor.cs: We want the override cursor to be reset to NULL when
+       we set current cursor to the default cursor.
+
+2007-02-05  Jackson Harper  <jackson@ximian.com>
+
+       * TextControl.cs: Don't have crlfs when we are non multiline.
+       - Consolidate the line position.
+
+2007-02-05  Jackson Harper  <jackson@ximian.com>
+
+       * X11Keyboard.cs: BACK+CTRL gets a special char code.
+
+2007-02-03  Rolf Bjarne Kvinge <RKvinge@novell.com> 
+
+       * XplatUIX11.cs: Implemented WM_CAPTURECHANGED support, we're now
+         handling LeaveNotify->NotifyUngrab in order to send
+         WM_CAPTURECHANGED. However sometimes the NotifyUngrab arrives late
+         after calling XUngrabPointer, so we call WindowUngrabbed directly
+         from UngrabWindow in order to send WM_CAPTURECHANGED immediately.
+       * Control.cs: Handle WM_CAPTURECHANGED in order to raise
+         MouseCaptureChanged correctly. Also create handles if changing
+         Capture (matches MS behaviour).
+
+2007-02-02  Rolf Bjarne Kvinge <RKvinge@novell.com> 
+
+       * SizeGrip.cs: Make the last change 2.0 only.
+
+2007-02-02  Rolf Bjarne Kvinge <RKvinge@novell.com> 
+
+       * SizeGrip.cs: If resizing and the capture is lost, revert any size
+         changes to initial size (fixes #80597).
+
+2007-02-02  Rolf Bjarne Kvinge <RKvinge@novell.com> 
+
+       * SizeGrip.cs: Use the normal icon for SizeGrip if it is disabled.
+
+2007-02-02  Rolf Bjarne Kvinge <RKvinge@novell.com> 
+
+       * SizeGrip.cs: Only draw sizegrip if enabled (but always draw
+         background) and only allow dragging if enabled. This way the
+         sizegrip can be used to fill the open square that otherwise would
+         have been shown in the bottom right corner of ScrollableControl
+         when ScrollableControl is not suppose to support sizing.
+       * ScrollableControl.cs: Create UpdateSizeGripVisible to decide when the
+         sizegrip is shown and enabled, and hook up with necessary events.
+
+2007-02-01  Chris Toshok  <toshok@ximian.com>
+
+       * DataGridTextBoxColumn.cs: clean up the
+       GetFormattedString/GetColumnValueAtRow combination of functions.
+       Also fix UpdateUI, and the initial state of
+       IsInEditOrNavigateMode.
+
+       * DataGridTextBox.cs: don't chain up to base.OnMouseWheel - we
+       aren't supposed to scroll the textbox here, we're supposed to
+       scroll the datagrid.
+
+2007-02-01  Chris Toshok  <toshok@ximian.com>
+
+       * ComboBox.cs: use vscrollbar_ctrl.Dock instead of explicitly
+       setting the position.
+
+2007-02-01  Chris Toshok  <toshok@ximian.com>
+
+       * DataGrid.cs (OnLeave): we can now do the CancelCurrentEdit thing
+       here, since the most recent focus fixes keep us from generating
+       the Leave event when our textbox gets focus.
+       (Edit): we should be passing null for the column style's
+       instantText parameter.
+       
+2007-02-01  Jonathan Pobst  <monkey@jpobst.com>
+
+       * ToolStripDropDownItem.cs: Make sure DropDownOpening event is 
+       raised.  Fixes menu text/icons not showing up in PDN.
+
+2007-02-01  Rolf Bjarne Kvinge  <RKvinge@novell.com>
+
+       * Control.cs: Remove code in constructor that makes every
+       control with WS_CHILD set have initial location -1, -1.
+
+2007-01-31  Jackson Harper  <jackson@ximian.com>
+
+       * X11Dnd.cs: Take the keyboard on init to reduce coupling with
+       XplatUIX11.
+       * XplatUIX11.cs: Give teh keyboard to teh dnd.
+
+2007-01-31  Jackson Harper  <jackson@ximian.com>
+
+       * X11Dnd.cs: Use IDataObject instead of the DataObject class.
+       - Remove some debug code.
+
+2007-01-31  Jackson Harper  <jackson@ximian.com>
+
+       * XplatUIX11.cs: If you set the override cursor during a grab, it
+       should actually override the grab cursor.  This comes into play
+       when you are setting custom cursors in a DND feedback method.
+
+2007-01-31  Jackson Harper  <jackson@ximian.com>
+
+       * X11Dnd.cs: Add support for handling the QueryContinue and
+       GiveFeedback events.
+       - Cancel drag and drop actions when the escape key is clicked.
+       * XplatUIX11.cs: Let the dnd subsystem get key events, so that it
+       can handle the ESCAPE key.
+       - Allow dnd to swallow BUTTONUP messages if it needs to.  This is
+       done when dnd events are continued after the button is released.
+       - Add a new helper method so that dnd can translate key events.
+
+2007-01-31  Alexander Olk  <alex.olk@googlemail.com>
+
+       * FileDialog.cs: Rewrite of Jacksons OnClickCancelButton patch to
+       make it more obvious what is happening.
+
 2007-01-30  Jackson Harper  <jackson@ximian.com>
 
        * XplatUIX11.cs: Don't break when handling button release in drag