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

Windows 7 Theme + Textbox

1 Answer 32 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Andrea
Top achievements
Rank 1
Andrea asked on 02 May 2014, 08:39 AM
Hi,

I've recently updated from 2013.2.0661.1050 to 2014.1.0224.1050 and I've noticed an odd quirk with a textbox. The cursor now always starts half way down the textbox. Looks like there is some padding going on? It only appears to be happening with textboxes with the height, textwrapping and accepts return properties set. I've narrowed this down to a style and I can trigger this behavior on and off by removing the reference to the Windows 7 theme. Any idea?

Style:

<telerik:Windows7Theme
       x:Key="Theme" />

    <Style
       x:Key="FormTextBoxBaseStyle"
       TargetType="TextBox"
       telerik:StyleManager.BasedOn="{StaticResource Theme}">
        <!--  NB: Telerik default Windows7 style sets this to 5,2 for SL and 3,2 for WPF in 2012 Q2 SP1. -->
        <Setter
           Property="Padding"
           Value="3, 2" />
        <Setter
           Property="VerticalAlignment"
           Value="Center" />
    </Style>

See attached files for the bug. Part highlighted in yellow can never contain text.

Any idea if there were changes to the Windows 7 theme recently that might have caused this?

Thanks,
Andrea

1 Answer, 1 is accepted

Sort by
0
Vera
Telerik team
answered on 02 May 2014, 02:45 PM
Hello Andrea,

Actually, this is the expected behavior after we eliminated some inconsistencies among our controls. You can easily avoid it by setting TextBox.VerticalContentAlignment property to Top.  

Please excuse us for the inconvenience caused.

Regards,
Vera
Telerik
 
Check out Telerik Analytics, the service which allows developers to discover app usage patterns, analyze user data, log exceptions, solve problems and profile application performance at run time. Watch the videos and start improving your app based on facts, not hunches.
 
Tags
General Discussions
Asked by
Andrea
Top achievements
Rank 1
Answers by
Vera
Telerik team
Share this question
or