Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Building Controls > How to add vertical align attribute to designer

Reply
Thread Tools

How to add vertical align attribute to designer

 
 
James Geurts
Guest
Posts: n/a
 
      08-16-2005
Hi,

I am trying to add designer support to my custom web control. It's similar
to the Panel control and I'd like to allow the user to specify vertical
align. I'm not quite sure what style is supported in the vs.net designer,
though.

So... in the OnBehaviorAttached() method of my designer class, I do
something like:

this.Behavior.SetStyleAttribute("vertical-align", true,
Enum.Format(typeof(VerticalAlign), propertyValue, "G"), true);

It doesn't appear that "vertical-align" is a valid style. Can someone tell
me what style I need to specify to accomplish this?

Also, is there a list of styles (and attributes) that are supported by the
vs.net designer?

Thanks

Jim
 
Reply With Quote
 
 
 
 
Jeff Bowman
Guest
Posts: n/a
 
      08-16-2005
Oops--layers don't support vertical alignment. It's a CSS issue, not a VS.NET
designer issue.

Now, that said, you might be able to find a CSS hack on Google--it's a hot
topic.




James Geurts wrote:
> Hi,
>
> I am trying to add designer support to my custom web control. It's similar
> to the Panel control and I'd like to allow the user to specify vertical
> align. I'm not quite sure what style is supported in the vs.net designer,
> though.
>
> So... in the OnBehaviorAttached() method of my designer class, I do
> something like:
>
> this.Behavior.SetStyleAttribute("vertical-align", true,
> Enum.Format(typeof(VerticalAlign), propertyValue, "G"), true);
>
> It doesn't appear that "vertical-align" is a valid style. Can someone tell
> me what style I need to specify to accomplish this?
>
> Also, is there a list of styles (and attributes) that are supported by the
> vs.net designer?
>
> Thanks
>
> Jim



 
Reply With Quote
 
 
 
 
James Geurts
Guest
Posts: n/a
 
      08-17-2005
Maybe I'm missing something, but how do layers factor into the designer? The
vs.net designer is just a glorified IE control, right? Is it that a
ReadWriteControlDesigner is not rendered as a div or span in the designer
view?

Again, I would like to know the styles and attributes that are supported
with the vs.net designer...

btw, vertical alignment is supported by CSS:
http://www.w3.org/TR/CSS1#vertical-align

Thanks

Jim

"Jeff Bowman" wrote:

> Oops--layers don't support vertical alignment. It's a CSS issue, not a VS.NET
> designer issue.
>
> Now, that said, you might be able to find a CSS hack on Google--it's a hot
> topic.
>
>
>
>
> James Geurts wrote:
> > Hi,
> >
> > I am trying to add designer support to my custom web control. It's similar
> > to the Panel control and I'd like to allow the user to specify vertical
> > align. I'm not quite sure what style is supported in the vs.net designer,
> > though.
> >
> > So... in the OnBehaviorAttached() method of my designer class, I do
> > something like:
> >
> > this.Behavior.SetStyleAttribute("vertical-align", true,
> > Enum.Format(typeof(VerticalAlign), propertyValue, "G"), true);
> >
> > It doesn't appear that "vertical-align" is a valid style. Can someone tell
> > me what style I need to specify to accomplish this?
> >
> > Also, is there a list of styles (and attributes) that are supported by the
> > vs.net designer?
> >
> > Thanks
> >
> > Jim

>
>
>

 
Reply With Quote
 
Jeff Bowman
Guest
Posts: n/a
 
      08-17-2005
James Geurts wrote:
> Maybe I'm missing something, but how do layers factor into the designer? The


The Panel control emits DIVs, which are layers.



> vs.net designer is just a glorified IE control, right? Is it that a
> ReadWriteControlDesigner is not rendered as a div or span in the designer
> view?


AFAIK, there's no way to access the HTML in designer view.



> Again, I would like to know the styles and attributes that are supported
> with the vs.net designer...


That one I don't know. In fact I'm kind of curious myself.



> btw, vertical alignment is supported by CSS:
> http://www.w3.org/TR/CSS1#vertical-align


Yes, for inline elements such as SPAN. DIV is a block-level element.

http://google.com/search?q=css+div+vertical+alignment



>
> Thanks
>
> Jim
>
> "Jeff Bowman" wrote:
>
>> Oops--layers don't support vertical alignment. It's a CSS issue, not a VS.NET
>> designer issue.
>>
>> Now, that said, you might be able to find a CSS hack on Google--it's a hot
>> topic.
>>
>>
>>
>>
>> James Geurts wrote:
>>> Hi,
>>>
>>> I am trying to add designer support to my custom web control. It's similar
>>> to the Panel control and I'd like to allow the user to specify vertical
>>> align. I'm not quite sure what style is supported in the vs.net designer,
>>> though.
>>>
>>> So... in the OnBehaviorAttached() method of my designer class, I do
>>> something like:
>>>
>>> this.Behavior.SetStyleAttribute("vertical-align", true,
>>> Enum.Format(typeof(VerticalAlign), propertyValue, "G"), true);
>>>
>>> It doesn't appear that "vertical-align" is a valid style. Can someone tell
>>> me what style I need to specify to accomplish this?
>>>
>>> Also, is there a list of styles (and attributes) that are supported by the
>>> vs.net designer?
>>>
>>> Thanks
>>>
>>> Jim



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: How include a large array? Edward A. Falk C Programming 1 04-04-2013 08:07 PM
<div align=center> also affects align of dynamic dropdown item text Steve Richter ASP .Net 1 06-24-2007 07:11 PM
left align within centre align Paul Lautman HTML 3 03-03-2006 02:45 PM
text-align vs align tshad HTML 1 06-23-2005 10:29 PM
how to Align text left & vertical align middle Kay ASP .Net 2 07-25-2003 08:32 AM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57