timelineview row and appointment height

Hi,

I work in timelineview mode.

I would like to set the height of appointments the same of row height to remove space between each row.


Is it possible?


Many Thanks

Jim


4 Replies 1 reply marked as answer

VM Vidyalakshmi Mani Syncfusion Team December 18, 2024 02:13 PM UTC

Hi Jim,


Thank you for contacting us. To customize the row and appointment heights in Timeline View, you can use one of the following options:


1. RowAutoHeight:  

   Enabling `RowAutoHeight` (set to `true`) will automatically adjust the row height based on the number of appointments. For detailed guidance, please refer to our User Guide documentation: Wpf/Scheduler/Resource-Grouping#Resource-Auto-Height


2. RowMinHeight:  

   The `RowMinHeight` property allows you to set a fixed minimum height for rows in Timeline View. You can find more information in our UG document: Wpf/scheduler/Resource-Grouping#Resource-Minimum-Height


3.Timeline Appointment Height:  

   The height of appointments can be customized using the `Timeline Appointment Height` property. For more details please check our User Guide: Wpf/Scheduler/TimelineView#Appointment-Height


If you have any other questions or need further assistance, please don't hesitate to reach out.


Regards,

Vidyalakshmi M.




TC the carpenter December 19, 2024 07:01 AM UTC

Hi,

Thank you but it doesn't work. I have the same problem. The row height is twice tall as appointment height

I would like appointment height the same as row height.

row height.jpg


Here is my xaml setting :

        <syncfusion:SfScheduler x:Name="Schedule" ShowBusyIndicator="True" ViewType="TimelineWorkWeek" ResourceGroupType="Resource" Margin="0,10,0,198" AppointmentEditFlag="Add,DragDrop,Edit,Resize" EnableToolTip="True" ViewChanged="Schedule_ViewChanged" AppointmentEditorOpening="Schedule_AppointmentEditorOpening">


            <syncfusion:SfScheduler.DaysViewSettings>

                <syncfusion:DaysViewSettings TimeInterval="15" />

            </syncfusion:SfScheduler.DaysViewSettings>


            <syncfusion:SfScheduler.TimelineViewSettings >

                <syncfusion:TimelineViewSettings ResourceHeaderSize="150" TimeRulerFormat="HH:mm" ViewHeaderTemplate="{StaticResource viewHeaderTemplate}" TimeInterval="15" RowAutoHeight="True" TimelineAppointmentHeight="50" RowMinHeight="50">

                    <syncfusion:TimelineViewSettings.AppointmentTemplate>

                        <DataTemplate>

                            <Border BorderThickness="3" BorderBrush="{Binding AppointmentBackground}" CornerRadius="5" VerticalAlignment="Stretch" >

                                <Border.Background>

                                    <LinearGradientBrush StartPoint="0,0.5" EndPoint="1,0.5">

                                        <GradientStop Color="Gray" Offset="0"/>

                                        <GradientStop Color="White" Offset="1"/>

                                    </LinearGradientBrush>

                                </Border.Background>

                                <StackPanel

                                VerticalAlignment="Stretch"

                                HorizontalAlignment="Stretch">

                                    <TextBlock Margin="5"

                                        Text="{Binding Subject}"

                                        Foreground="{Binding ForegroundColor}"

                                        TextWrapping="WrapWithOverflow"

                                        VerticalAlignment="Stretch"

                                        HorizontalAlignment="Stretch"

                                        FontStyle="Normal"

                                        TextAlignment="Left"

                                        FontWeight="Bold" FontSize="13"/>

                            </StackPanel>

                            </Border>

                        </DataTemplate>

                    </syncfusion:TimelineViewSettings.AppointmentTemplate>

                </syncfusion:TimelineViewSettings>

            </syncfusion:SfScheduler.TimelineViewSettings>

       

        </syncfusion:SfScheduler>


Thank you for your help,


Jim




TC the carpenter December 20, 2024 07:29 AM UTC

Hi,


I found it. You need to set  the two parameters CellBottomPadding and TimelineAppointmentHeight


Example :

TimelineAppointmentHeight = 50

CellBottomPadding=-50  --> To remove space between rows


Thanks


Marked as answer

VM Vidyalakshmi Mani Syncfusion Team December 20, 2024 09:42 AM UTC

Hi Jim,


We are glad that your issue has been resolved! Please let us know if you need further assistance. As always, we are happy to help you out.


Regards,

Vidyalakshmi M.


Loader.
Up arrow icon