Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. General Programming
  3. WPF
  4. Font difference between XP and Vista in wpf app

Font difference between XP and Vista in wpf app

Scheduled Pinned Locked Moved WPF
csharpwpfhelpquestion
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    ausadmin
    wrote on last edited by
    #1

    We have a wpf app developed under windows XP SP2. When this app runs under Vista, the text gets clipped in many places - it is as though a different font is used which is slightly larger. I have seen this with both Tahoma and Arial. I could go through and add padding or miniumum height to solve the, but it seems as though that should not be necessary (and may lead to other problems). Has anyone else experienced this? Can anyone provide some advice or pointers? A sample style is as follows:

    <Style x:Key="Heading3" TargetType="{x:Type TextBlock}">
    <Setter Property="FontWeight" Value="Bold"/>
    <Setter Property="Foreground" Value="{DynamicResource textDimmedForegroundBrush}" />
    <Setter Property="HorizontalAlignment" Value="Left" />
    <Setter Property="FontFamily" Value="Arial"/>
    </Style>

    Thanks for any help, Tim

    C 1 Reply Last reply
    0
    • A ausadmin

      We have a wpf app developed under windows XP SP2. When this app runs under Vista, the text gets clipped in many places - it is as though a different font is used which is slightly larger. I have seen this with both Tahoma and Arial. I could go through and add padding or miniumum height to solve the, but it seems as though that should not be necessary (and may lead to other problems). Has anyone else experienced this? Can anyone provide some advice or pointers? A sample style is as follows:

      <Style x:Key="Heading3" TargetType="{x:Type TextBlock}">
      <Setter Property="FontWeight" Value="Bold"/>
      <Setter Property="Foreground" Value="{DynamicResource textDimmedForegroundBrush}" />
      <Setter Property="HorizontalAlignment" Value="Left" />
      <Setter Property="FontFamily" Value="Arial"/>
      </Style>

      Thanks for any help, Tim

      C Offline
      C Offline
      Christian Graus
      wrote on last edited by
      #2

      I've had this happen, it's a real PITA. i suspect you can get around it by making sure you set the font size explicitly, but even then, I think the best thing to do is to make sure you test on both and that you provide space for both.

      Christian Graus Driven to the arms of OSX by Vista. Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups