[Mono-bugs] [Bug 81791][Nor] New - The propertygrid doesn't allow editing without workaround.
bugzilla-daemon at bugzilla.ximian.com
bugzilla-daemon at bugzilla.ximian.com
Fri Jun 1 04:19:51 EDT 2007
Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.
Changed by mikael.modin at instrumentcontrol.se.
http://bugzilla.ximian.com/show_bug.cgi?id=81791
--- shadow/81791 2007-06-01 04:19:51.000000000 -0400
+++ shadow/81791.tmp.5438 2007-06-01 04:19:51.000000000 -0400
@@ -0,0 +1,76 @@
+Bug#: 81791
+Product: Mono: Class Libraries
+Version: 1.2
+OS:
+OS Details: XP
+Status: NEW
+Resolution:
+Severity:
+Priority: Normal
+Component: Windows.Forms
+AssignedTo: toshok at ximian.com
+ReportedBy: mikael.modin at instrumentcontrol.se
+QAContact: mono-bugs at ximian.com
+TargetMilestone: ---
+URL:
+Cc:
+Summary: The propertygrid doesn't allow editing without workaround.
+
+Description of Problem:
+The PropertyGrid doesn't allow editing of members that require keyboard
+input. It does change color-properties and other properties that circle
+through lists but fields that require input from the keyboard can't be edited.
+
+Steps to reproduce the problem:
+1. Create a windows form
+2. Add a property grid
+3. set grid.selectedObject = new Button(); or class of your choice.
+4. try to edit a textfield.
+
+Actual Results:
+The grid doesn't allow editing of members. It does change color-properties
+and other properties that circle through lists but fields that require
+input from the keyboard can't be edited.
+
+Expected Results:
+To be allowed to edit fields that require keyboard input.
+
+How often does this happen?
+Every time.
+
+Additional Information:
+It can be worked around by putting the field in a "invisible" TabControl,
+source excerpt:
+
+public partial class ObjectEditorForm : Form
+ {
+ delegate void tickDelegate();
+ ...
+ Timer t = new Timer();
+ public ObjectEditorForm(ref object toBeEdited) {
+ grid = new PropertyGrid();
+ InitializeComponent();
+ OldObject = toBeEdited;
+ newObject = toBeEdited;
+
+ t.Tick += new EventHandler(Tick);
+ t.Interval = 1;
+ t.Enabled = true;
+ }
+ void Tick(object sender, EventArgs e)
+ {
+ if (InvokeRequired) {
+ BeginInvoke(new tickDelegate(initTabs));
+ return;
+ }
+ initTabs();
+ }
+
+ private void initTabs() {
+ t.Enabled = false;
+ this.OnMouseClick(new MouseEventArgs(MouseButtons.Left, 1, 100,
+10, 0));
+ tabControl1.SelectedTab = tabPage1;
+ tabControl1.SelectedTab = tabPage2;
+ tabControl1.SelectedTab = tabPage1;
+ }
More information about the mono-bugs
mailing list