This is a migrated thread and some comments may be shown as answers.

How to set GanttView row Height

4 Answers 247 Views
GanttView
This is a migrated thread and some comments may be shown as answers.
Kourosh
Top achievements
Rank 1
Kourosh asked on 29 May 2018, 09:58 AM

Hi,

 

How can I set row height in ganttview?

 

Best Regards

Kourosh

4 Answers, 1 is accepted

Sort by
0
Dilyan Traykov
Telerik team
answered on 31 May 2018, 02:40 PM
Hello Kourosh,

To change the height of the rows inside the RadGanttView control, you can use an approach similar to the one suggested by my colleague in the following thread.

Please let me know if this would work for you.

Regards,
Dilyan Traykov
Progress Telerik
Want to extend the target reach of your WPF applications, leveraging iOS, Android, and UWP? Try UI for Xamarin, a suite of polished and feature-rich components for the Xamarin framework, which allow you to write beautiful native mobile apps using a single shared C# codebase.
0
Kourosh
Top achievements
Rank 1
answered on 02 Jun 2018, 03:48 AM

Hi Dylian,
Although it is mentioned in the thread as point number 2 as below:
"2) Change the SimpleCellContainerStyle, CellContainerStyle, CellEditingContainerStyle and SimpleTreeCellContainerStyle to set the MinHeight to 35."
but there is nothing about changing row height in attached example/sample in that thread you mentioned.
Am I wrong? Please let me know.

Best Regards

Kourosh

0
Kourosh
Top achievements
Rank 1
answered on 02 Jun 2018, 03:58 AM

Hi again Dilyan,

This is my solution in case someone else wanted it, based on your guidance:

<Style TargetType="telerik:SimpleCellContainer" BasedOn="{StaticResource SimpleCellContainerStyle}">
            <Setter Property="MinHeight" Value="32" />
        </Style>
        <Style TargetType="telerik:CellContainer" BasedOn="{StaticResource CellContainerStyle}">
            <Setter Property="MinHeight" Value="32" />
        </Style>
        <Style TargetType="telerik:CellEditingContainer" BasedOn="{StaticResource CellEditingContainerStyle }">
            <Setter Property="MinHeight" Value="32" />
        </Style>
        <Style TargetType="telerik:SimpleTreeCellContainer" BasedOn="{StaticResource SimpleTreeCellContainerStyle }">
            <Setter Property="MinHeight" Value="32" />
        </Style>

        <Style TargetType="telerik:DragResizeSlotHighlightContainer" BasedOn="{StaticResource DragResizeSlotHighlightContainerStyle}">
            <Setter Property="MinHeight" Value="16" />
        </Style>
        <Style TargetType="telerik:CellHighlightContainer" BasedOn="{StaticResource CellHighlightContainerStyle}">
            <Setter Property="MinHeight" Value="32" />
        </Style>

 

I am adding 2 more styles for Drag and drop and also cell highlight. Based on my experience row height changes with only 3 first styles set. What is the absolute minimum to get the job done? and are there any other styles I should add? 

Am I right?

Please do comment. 

Best Regards

Kourosh

0
Vladimir Stoyanov
Telerik team
answered on 05 Jun 2018, 03:56 PM
Hello Kourosh,

I am glad to hear that you managed to achieve the desired look. Thank you for sharing the solution.

The minimum amount of styles required to modify the row height would depend on the exact setup on your side. That said it seems that you have added all the necessary styles for achieving this customization.

On a side note, you can check out the GanttView Styles article in our documentation if you have not done so already. 

Regards,
Vladimir Stoyanov
Progress Telerik
Want to extend the target reach of your WPF applications, leveraging iOS, Android, and UWP? Try UI for Xamarin, a suite of polished and feature-rich components for the Xamarin framework, which allow you to write beautiful native mobile apps using a single shared C# codebase.
Tags
GanttView
Asked by
Kourosh
Top achievements
Rank 1
Answers by
Dilyan Traykov
Telerik team
Kourosh
Top achievements
Rank 1
Vladimir Stoyanov
Telerik team
Share this question
or