[Mono-winforms-list] Month Calendar and NumericUpDown Control

2005-06-10 Thread jba
Hey guys,

I saw a commit that said NumericUpDown was implemented so I wired it
into MonthCalendar (which should now be considered feature complete).

Along the way I discovered what I think are bugs in NumericUpDown. If
NumericUpDown is not actually complete yet then feel free to ignore
these points:

- Setting the Value property for the numeric up down control while it's
not visible results in that value not being set. I believe the flow is
this:
Set .Visible = false
Set .Minimum 
.Value now has .Minimum as it's value
Set .Value;
.Value calls one of the updateedit method which inturn uses a parseedit
method which for some reason reads the minimum value as the current text
and so .Value gets reset to parsed minimum value.

- It's not responding to Readonly property correctly (.ReadOnly = true
means up/down buttons work but not text editing.

- It seems to render buttons on windows for me, but not on linux

- It doesn't seem to be handling the key press events (this may be an
issue with the way I'm using it though).

There was something else about the way MonthCalendar render's on linux
but I can't remember it now. Will send that through when I remember.

Regards,

JBA

___
Mono-winforms-list maillist  -  Mono-winforms-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-winforms-list


Re: [Mono-winforms-list] Month Calendar and NumericUpDown Control

2005-06-10 Thread Jonathan Gilbert
At 10:37 PM 10/06/2005 +1000, JBA wrote:
>Hey guys,
>
>I saw a commit that said NumericUpDown was implemented so I wired it
>into MonthCalendar (which should now be considered feature complete).
>
>Along the way I discovered what I think are bugs in NumericUpDown. If
>NumericUpDown is not actually complete yet then feel free to ignore
>these points:

Well, it should essentially be complete, but let's see what you've got.

>- Setting the Value property for the numeric up down control while it's
>not visible results in that value not being set. I believe the flow is
>this:
>   Set .Visible = false
>   Set .Minimum 
>   .Value now has .Minimum as it's value
>   Set .Value;
>   .Value calls one of the updateedit method which inturn uses a parseedit
>method which for some reason reads the minimum value as the current text
>and so .Value gets reset to parsed minimum value.

I wrote up a test case but was unable to reproduce your results. Can you
reduce it to a minimal test case for me?

>- It's not responding to Readonly property correctly (.ReadOnly = true
>means up/down buttons work but not text editing.

This is the correct behaviour for .ReadOnly.

>- It seems to render buttons on windows for me, but not on linux

This is probably a bug in mono's ControlPaint or whatever ControlPaint
calls (something in the theme library).

>- It doesn't seem to be handling the key press events (this may be an
>issue with the way I'm using it though).

It does for me :-)

>There was something else about the way MonthCalendar render's on linux
>but I can't remember it now. Will send that through when I remember.

Okay :-)

Jonathan Gilbert
___
Mono-winforms-list maillist  -  Mono-winforms-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-winforms-list


Re: [Mono-winforms-list] Month Calendar and NumericUpDown Control

2005-06-10 Thread Peter Dennis Bartok
John,

I cannot reproduce the described issue with Value not being set when on a 
invisible control. I did a testcase where I set the value before the control 
is added to it's parent, and the control is only displayed if I click a 
button. The control then shows up properly, with the set value in the text 
field.

The Readonly issue is a textbox issue, which will be fixed as part of the 
ongoing textbox work

I fixed focus handling, which affected keyboard handling, as of r45760. It 
will need more fixing, though, since we don't handle tabbing off the control 
properly yet.

Cheers,
  Peter

-Original Message-
From: "jba" <[EMAIL PROTECTED]>
To: "Mono-Winforms-List (E-mail)" <[EMAIL PROTECTED]>
Date: 10 June, 2005 06:37
Subject: [Mono-winforms-list] Month Calendar and NumericUpDown Control


>Hey guys,
>
>I saw a commit that said NumericUpDown was implemented so I wired it
>into MonthCalendar (which should now be considered feature complete).
>
>Along the way I discovered what I think are bugs in NumericUpDown. If
>NumericUpDown is not actually complete yet then feel free to ignore
>these points:
>
>- Setting the Value property for the numeric up down control while it's
>not visible results in that value not being set. I believe the flow is
>this:
> Set .Visible = false
> Set .Minimum
> .Value now has .Minimum as it's value
> Set .Value;
> .Value calls one of the updateedit method which inturn uses a parseedit
>method which for some reason reads the minimum value as the current text
>and so .Value gets reset to parsed minimum value.
>
>- It's not responding to Readonly property correctly (.ReadOnly = true
>means up/down buttons work but not text editing.
>
>- It seems to render buttons on windows for me, but not on linux
>
>- It doesn't seem to be handling the key press events (this may be an
>issue with the way I'm using it though).
>
>There was something else about the way MonthCalendar render's on linux
>but I can't remember it now. Will send that through when I remember.
>
>Regards,
>
>JBA
>
>___
>Mono-winforms-list maillist  -  Mono-winforms-list@lists.ximian.com
>http://lists.ximian.com/mailman/listinfo/mono-winforms-list
>
> 

___
Mono-winforms-list maillist  -  Mono-winforms-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-winforms-list


[Fwd: Re: [Mono-winforms-list] Month Calendar and NumericUpDown Control]

2005-06-11 Thread jba
keep forgetting to copy the list
--- Begin Message ---
On Fri, 2005-06-10 at 11:31 -0400, Jonathan Gilbert wrote:
> At 10:37 PM 10/06/2005 +1000, JBA wrote:
> >Hey guys,
> >
> >I saw a commit that said NumericUpDown was implemented so I wired it
> >into MonthCalendar (which should now be considered feature complete).
> >
> >Along the way I discovered what I think are bugs in NumericUpDown. If
> >NumericUpDown is not actually complete yet then feel free to ignore
> >these points:
> 
> Well, it should essentially be complete, but let's see what you've got.
> 
> >- Setting the Value property for the numeric up down control while it's
> >not visible results in that value not being set. I believe the flow is
> >this:
> > Set .Visible = false
> > Set .Minimum 
> > .Value now has .Minimum as it's value
> > Set .Value;
> > .Value calls one of the updateedit method which inturn uses a parseedit
> >method which for some reason reads the minimum value as the current text
> >and so .Value gets reset to parsed minimum value.
To repro this just run the monthcalendar example in the winforms svn
module. The first calendar is November 2004. When you click on the year,
it sets the Value of the NumericUpDown to 2004 (while it's not visible)
and then displays it. The thing is that when it displays the
NumericUpDown it is set to 1953 not 2004 (1953 is the minimum value).
> 
> I wrote up a test case but was unable to reproduce your results. Can you
> reduce it to a minimal test case for me?
> 
> >- It's not responding to Readonly property correctly (.ReadOnly = true
> >means up/down buttons work but not text editing.
> 
> This is the correct behaviour for .ReadOnly.
Yeah it is, except the numericupdown doesn't do this. Peter said it was
due to textbox anyhow.
> 
> >- It seems to render buttons on windows for me, but not on linux
> 
> This is probably a bug in mono's ControlPaint or whatever ControlPaint
> calls (something in the theme library).
> 
> >- It doesn't seem to be handling the key press events (this may be an
> >issue with the way I'm using it though).
> 
> It does for me :-)
> 
> >There was something else about the way MonthCalendar render's on linux
> >but I can't remember it now. Will send that through when I remember.
> 
> Okay :-)
> 
> Jonathan Gilbert
--- End Message ---
___
Mono-winforms-list maillist  -  Mono-winforms-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-winforms-list