Custom property editor erase all control properties

R

R.A.F.

Hi,

I have a custom control in which i have a collection property named
"Columns".

this collection property add/remove column objects.
in my Column class i have a property named Alignment which use a custom
property editor.

when this property editor is not linked to this property,

My property grid displays all properties of my Column object.
When my custom UIeditor is linked via
[Editor(typeof(AlignmentDropDownEditor), typeof(UITypeEditor))] all
properties of my Column object are hidden (property grid is empty of not
only property value, but also categories and property names...

where could be the mistake ?
Could it come from property converter ?
this property is in fact a class which consists of 2 public properties :
Alignment -> Vertical
Alignment -> Horizontal

for information, my UIEditor is a dropdown UIEditor.

thanks a lot,

RAF.
 
R

R.A.F.

Ok, i found the problem... :)

but while my custom UIEditor is based on a UserControl of 66 x 66
pixels, it is displayed by property editor like completly reduce and
only on the left half of the "form" of dropdown window.

How is it possible ?

thx.

RAF.
 
N

Nicholas Paldino [.NET/C# MVP]

RAF,

The control is going to be sized by the property grid, not by you. You
have to take into account the size that you are given, and adjust your
control accordingly. If this doesn't work for you, then you would be better
off using a modal dialog.


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

R.A.F. said:
Ok, i found the problem... :)

but while my custom UIEditor is based on a UserControl of 66 x 66 pixels,
it is displayed by property editor like completly reduce and only on the
left half of the "form" of dropdown window.

How is it possible ?

thx.

RAF.


R.A.F. said:
Hi,

I have a custom control in which i have a collection property named
"Columns".

this collection property add/remove column objects.
in my Column class i have a property named Alignment which use a custom
property editor.

when this property editor is not linked to this property,

My property grid displays all properties of my Column object.
When my custom UIeditor is linked via
[Editor(typeof(AlignmentDropDownEditor), typeof(UITypeEditor))] all
properties of my Column object are hidden (property grid is empty of not
only property value, but also categories and property names...

where could be the mistake ?
Could it come from property converter ?
this property is in fact a class which consists of 2 public properties :
Alignment -> Vertical
Alignment -> Horizontal

for information, my UIEditor is a dropdown UIEditor.

thanks a lot,

RAF.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top