Custom Shapedform

4 posts, 1 answers
  1. Dominik
    Dominik avatar
    59 posts
    Member since:
    Dec 2012

    Posted 21 Oct 2015 Link to this post

    Hi,

    I am trying to create custom shaped form but I do not see the difference:

     

    public partial class FormToolTipError : Telerik.WinControls.UI.ShapedForm
    {
        public FormToolTipError()
        {
            InitializeComponent();
             
            Telerik.WinControls.CustomShape customShape = new Telerik.WinControls.CustomShape();
            customShape.AsString = "20,20,200,100:20,20,False,0,0,0,0,0:220,20,False,0,0,0,0,0:220,120,False,0,0,0,0,0:20,120,False,0,0,0,0,0:";
            this.Shape = customShape;
     
            ...

     

     

  2. Answer
    Dimitar
    Admin
    Dimitar avatar
    1404 posts

    Posted 21 Oct 2015 Link to this post

    Hello Dominic,

    Thank you for writing.

    It appears that your shape represents a rectangle and this is why you cannot see the difference. You can test this with the following code:
    public RadForm1()
    {
        InitializeComponent();
      
        this.Shape = new StarShape();
    }

    You can use the ShapeEditor to create a custom shape.

    Please let me know if there is something else I can help you with.

    Regards,
    Dimitar
    Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  3. UI for WinForms is Visual Studio 2017 Ready
  4. Dominik
    Dominik avatar
    59 posts
    Member since:
    Dec 2012

    Posted 21 Oct 2015 Link to this post

    It worked when i am using Shape Editor in Visual Style Builder. :)

    Then string is generated properly:

    "20,20,200,100:20,20,False,0,0,0,0,0:220,20,False,0,0,0,0,0:220,96,False,0,0,0,0,0:64,96,False,0,0,0,0,0:32,119.9637,False,0,0,0,0,0:32,96,False,0,0,0,0,0:19.9637,96,False,0,0,0,0,0:"

    Now i know that something is wrong when I am using Shape Editor directly in Visual Studio. After saving i can see the ​difference in Design, but the generated code is wrong:

    "20,20,200,100:20,20,False,0,0,0,0,0:220,20,False,0,0,0,0,0:220,120,False,0,0,0,0,0:20,120,False,0,0,0,0,0:"

    And then after closing and opening form shape goes to rectangle again.

    Thanks for help, and please add this as a bug.

  5. Dimitar
    Admin
    Dimitar avatar
    1404 posts

    Posted 22 Oct 2015 Link to this post

    Hi Dominic,

    Thank you for writing back.

    I was able to reproduce the issue where the shape is reset at design time. I have logged it in our Feedback Portal. You can track the item for status changes and add your vote for it here.
     
    Your Telerik Points have been updated for this report.

    Should you have any other questions do not hesitate to ask.


    Regards,
    Dimitar
    Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Back to Top