Print Page | Close Window

[SOLVED]Bug in TaskDialogs in 19.2

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Toolkit Pro
Forum Description: Topics Related to Codejock Toolkit Pro
URL: http://forum.codejock.com/forum_posts.asp?TID=24033
Printed Date: 26 April 2024 at 12:31pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: [SOLVED]Bug in TaskDialogs in 19.2
Posted By: pjna
Subject: [SOLVED]Bug in TaskDialogs in 19.2
Date Posted: 06 August 2020 at 9:33am
I would like to report a bug in Toolkit Pro in 19.2.0 in the Task Dialog class. I have upgraded the application I develop from Toolkit Pro 19.1.0 to 19.2.0 and noticed an issue in the CXTPTaskDialog class when icons are enabled with command link buttons. Here is a sample task dialog from my application using 19.1.0:


Upon upgrading to 19.2.0, this dialog becomes:



Notice how the text is much bigger and clipped which is the problem. I have diffed the CodeJock Task Dialog code between 19.1.0 and 19.2.0 and can see that the code which draws the icon has been reworked to use XAML buttons and a vector image but the XAML text it uses seems to use a hard coded font size:

<StackPanel Orientation='Horizontal'>
<Viewbox Stretch='Uniform'>
  <Canvas Width='16' Height='16' Canvas.Left='0' Canvas.Top='0'>
    <Line X1='0'  Y1='8'  X2='16' Y2='8' Stroke='#3E79B4' StrokeThickness='2' StrokeEndLineCap='Round'/>
    <Line X1='11' Y1='3'  X2='16' Y2='8' Stroke='#3E79B4' StrokeThickness='2' StrokeEndLineCap='Round'/>
    <Line X1='11' Y1='13' X2='16' Y2='8' Stroke='#3E79B4' StrokeThickness='2' StrokeEndLineCap='Round'/>
  </Canvas>
</Viewbox>
  <TextBlock Padding='5, 0, 0, 0' FontSize='16' FontQuality='ClearType' VerticalAlignment='Center'>%s</TextBlock>
</StackPanel>

which seems to be causing the problem along with the wrong calculation of the button ideal sizes. This issue is not related to high DPI and occurs when my display is set to 100 percent.

The only workaround I have found is to disable icons on the command link buttons using:

taskDlg.EnableCommandLinks(TRUE, FALSE);

which results in the following:



but ideally I would link the icon back on the buttons. I have looked at the code and I can change the code by overriding the virtual function CXTPTaskDialogClient::CreateLinkButtons in my class, but ideally I would like this issue fixed or a feature added which allows the old 19.1.0 behaviour of command link icons back.

Regards,
PJ Naughter



Replies:
Posted By: agontarenko
Date Posted: 11 August 2020 at 3:15am
Hello,

I'm glad to inform you that the issue has been addressed and fixed.
The fix will be available in the next beta or final release.
19.3 will be soon.

Regards,
Artem Gontarenko



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net