@@ -1693,26 +1693,26 @@ def watch_hover_style(
16931693 self .highlight_link_id = hover_style .link_id
16941694
16951695 def watch_scroll_x (self , old_value : float , new_value : float ) -> None :
1696- self .horizontal_scrollbar .position = round ( new_value )
1697- if (old_value ) != (new_value ):
1696+ self .horizontal_scrollbar .position = new_value
1697+ if round (old_value ) != round (new_value ):
16981698 self ._refresh_scroll ()
16991699
17001700 def watch_scroll_y (self , old_value : float , new_value : float ) -> None :
1701- self .vertical_scrollbar .position = round ( new_value )
1702- if (old_value ) != (new_value ):
1701+ self .vertical_scrollbar .position = new_value
1702+ if round (old_value ) != round (new_value ):
17031703 self ._refresh_scroll ()
17041704
17051705 def validate_scroll_x (self , value : float ) -> float :
17061706 return clamp (value , 0 , self .max_scroll_x )
17071707
17081708 def validate_scroll_target_x (self , value : float ) -> float :
1709- return clamp (value , 0 , self .max_scroll_x )
1709+ return round ( clamp (value , 0 , self .max_scroll_x ) )
17101710
17111711 def validate_scroll_y (self , value : float ) -> float :
17121712 return clamp (value , 0 , self .max_scroll_y )
17131713
17141714 def validate_scroll_target_y (self , value : float ) -> float :
1715- return clamp (value , 0 , self .max_scroll_y )
1715+ return round ( clamp (value , 0 , self .max_scroll_y ) )
17161716
17171717 @property
17181718 def max_scroll_x (self ) -> int :
0 commit comments