Page MenuHomeFeedback Tracker

ctrlStructuredText Wrong Color Format
New, NormalPublic

Description

Due to a not defined color format in the base class ctrlStructuredText the error "Wrong color format" is logged to the rpt when creating a control with ctrlCreate. On another note this also makes the use of links inside this type of control unappealing as they look just like normal text. Also affects controls which inherit from it w/o adjusting the below:

class ctrlStructuredText: ctrlDefaultText
{
	type=13;
	colorBackground[]={0,0,0,0};
	size="4.32 * (1 / (getResolution select 3)) * pixelGrid * 0.5";
	text="";
	class Attributes
	{
		align="left";
		color="#ffffff";
		colorLink="";
		size=1;
		font="RobotoCondensedLight";
	};
	onCanDestroy="";
	onDestroy="";
};

When setting the colorLink attribute to a valid hex color it works fine. Creating new controls is still not possible.

EDIT - The crash turned out to be of another origin (for some reason when using ctrlCreate with ctrlEdit base class). Edited the task accordingly.

Details

Severity
Minor
Resolution
Open
Reproducibility
Always
Operating System
Windows 10
Operating System Version
1803
Category
Config
Steps To Reproduce
_ctrl = _display ctrlCreate ["ctrlStructuredText",-1];
_ctrl ctrlSetStructuredText parseText "Normal text. <a href='google.com'>Link</a>. Normal text.";

The "Link" and the "Normal text" will look the same.

Additional Information

Error report:

Event Timeline

7erra created this task.May 20 2019, 9:26 PM
7erra renamed this task from Game Crash: ctrlStructuredText Wrong Color Format to ctrlStructuredText Wrong Color Format.May 21 2019, 12:26 PM
7erra updated the task description. (Show Details)
7erra changed Severity from Crash to Minor.
7erra changed Reproducibility from Random to Always.
7erra edited Steps To Reproduce. (Show Details)
7erra edited Additional Information. (Show Details)
7erra added a comment.Jan 28 2020, 7:19 PM

Bug is still present and still annoying. Fix would be:

class Attributes
{
	colorLink="#5555ff";
};

should be fixed in 1.99.146547