View Issue Details

IDProjectCategoryView StatusLast Update
0002883FSSCPgraphicspublic2014-08-21 08:45
ReporterAxem Assigned Toniffiwan  
PrioritynormalSeverityminorReproducibilityalways
Status resolvedResolutionreopened 
Summary0002883: Number 1 doesn't correct when using font03.vf
DescriptionIf the font is set to font03.vf and you try to write the number 1, you get a capital C-Cedilla instead. I am guessing this is because for some crazy reason the game uses the 128th slot for the number 1 (which ARE 1's in font01 and font02), but in font03 is a C-Cedilla.

See attached picture for a font tool screenshot showing the problem there.

Left window: font03.vf, right window: font01.vf
TagsNo tags attached.

Activities

Axem

2013-06-02 23:35

reporter  

fonttrouble.jpg (130,191 bytes)   
fonttrouble.jpg (130,191 bytes)   

Backslash

2013-06-06 03:17

developer   ~0015120

It uses that 128th slot number 1 because it is monospaced, and the regular 1 isn't.

Thus, the bug is more about when the game is deciding to make that substitution. It makes sense for hud numbers, but not much else. Even hud messages should probably not have it done... wonder if this was a tiny thing that got overlooked in the hud overhaul that has been missed until now.

So, in what situations are you using font03 that this happens? Messages? Briefing? Subtitles?

Axem

2013-06-08 12:48

reporter   ~0015123

Yeah it just appears to be in strings on the hud. I even found the function function that turns the 1 into a monospaced 1. :p

MjnMixael

2013-09-02 13:04

manager  

ImageBin.jpg (512,657 bytes)

MjnMixael

2013-09-02 13:05

manager   ~0015259

Last edited: 2013-09-03 02:33

I've uploaded another image. I'm using the straight up default font and I just noticed recently that some of the 1s are just gone. I'll have to do some work to find the revision this appeared in though.

EDIT: My specific issue showed up with revision 9761.

karajorma

2013-09-03 12:32

administrator   ~0015264

Fix committed to trunk@9767.

Axem

2013-09-03 21:19

reporter   ~0015266

I think mjn's problem was a different problem, because my original issue isn't fixed with the latest nightly.

niffiwan

2013-09-12 01:23

developer   ~0015270

Is this an asset problem? i.e. the characters in font1.vf are different to font03.vf - so any fix at best would be a special case?

i.e.
if (fontfile == "font03.vf" && character_index == 128)
  substitute font01.vf char 128

Also, it is possible to get a mission/mod to demonstrate the problem in-game?

Yarn

2013-09-14 23:08

developer   ~0015272

The problem is that the special symbols in font01.vf and font03.vf begin at different indices. These symbols include stuff like the monospaced 1, the infinity symbol, and the copyright symbol. They're used primarily for the HUD, although they're also found elsewhere: for example, the bottom text of the pilot selection screen uses the copyright symbol. Here are the symbol offsets for each of the font files:

font01.vp (English): 127
font01.vp (German): 164
font02.vp: Nowhere. Really.
font03.vp: 176

The symbol offset that the game actually uses is either 127 or 164, depending on the language, although this can be changed by defining a list of supported languages in strings.tbl. This offset must match the font file's symbol offset, or else those symbols will be either wrong or missing. Unfortunately, there doesn't appear to be a way to specify different offsets for different fonts.

Axem

2013-09-17 19:37

reporter  

badfonts-hdg.tbm (1,028 bytes)

Axem

2013-09-17 19:38

reporter   ~0015275

Last edited: 2013-09-17 19:39

I've attached a hud gauge tbm to this report, just drop it in a table directory and launch a mission. There's three gauges, each with a different font.

It's also worth noting that when you use stuff like scripting or the fiction viewer with the trouble-some fonts, do you get the correct number.

niffiwan

2013-10-22 04:08

developer   ~0015344

Last edited: 2013-10-22 06:57

right - this is the problem function: hud_num_make_mono

Need to update it to handle the different offsets in the different font files for different languages.

<strike>Also - if font02 doesn't have any special characters, is there a non-mono-spaced "1" at offset 128?</strike>

From testing with the attached table, I'm guessing there's nothing at offset 128 in font2...

Axem

2013-10-22 11:01

reporter   ~0015345

fonttool.exe seems to indicate that font02 only goes up to 126

niffiwan

2013-10-26 23:01

developer   ~0015349

Patch is ready. Seems to work OK with the provided test case. Axem - could you confirm this also fixes the issues in your JAD missions?

Yarn

2013-10-26 23:21

developer   ~0015350

I would set font03's symbol index to 176 for all languages, not just English and German. (This could be changed later if it turns out that the French or Polish version comes with a different version of font03.)

niffiwan

2013-10-26 23:29

developer   ~0015351

Last edited: 2013-10-26 23:41

yeah - that sounds like a decent idea, I'll add that to the patch

edit: and done

Yarn

2013-10-27 00:00

developer   ~0015352

I just noticed another thing. In this part of your patch:

+ required_string("+Special Character Index:");
+ stuff_ubyte(&language.special_char_indexes[0]);
+ for (i = 1; i < MAX_FONTS; ++i) {
+ // we might get font indexes from fonts.tbl later, but for now set them to "none"
+ language.special_char_indexes[i] = 0;
+ }

it looks like font03's symbol index is being set to 0 instead of 176 for languages defined in strings.tbl.

niffiwan

2013-10-27 00:16

developer   ~0015353

Last edited: 2013-10-27 00:37

Yes, that will occur if a modder adds an inbuilt language to strings.tbl. I'm working on another patch (not included with this one because it's not strictly related to the number problem, and it's not finished yet :)) which will allow modders to set individual indexes for fonts, as per this post.

http://www.hard-light.net/forums/index.php?topic=85041.msg1716554#msg1716554

In other words, once the next patch is ready, if a modder wishes to override an inbuilt languages settings then they will need to define the indexes correctly in fonts.tbl as well as and add details to strings.tbl (including the 1st font index, although that could probably be made optional at that point).

Does that make sense and sound reasonable?

Yarn

2013-10-27 00:41

developer   ~0015354

What I'm trying to say is that font03's symbol index should default to 176 for all languages, even those that are defined in strings.tbl. Of course, it should still be possible to change this in fonts.tbl. But if you're using only the default fonts, you shouldn't have to define extra stuff in fonts.tbl just because you've added some languages to strings.tbl.

niffiwan

2013-10-27 00:54

developer   ~0015355

Last edited: 2013-10-27 01:01

OK - I see what you're saying. I'll change it so the default setting for font03 is 176 for new languages added in strings.tbl.

And done: thanks for reviewing this :)

niffiwan

2013-10-27 01:00

developer  

mantis2883-svn.patch (13,767 bytes)   
Index: code/hud/hud.h
===================================================================
--- code/hud/hud.h	(revision 9982)
+++ code/hud/hud.h	(working copy)
@@ -14,6 +14,7 @@
 #include "graphics/2d.h"
 #include "hud/hudparse.h"
 #include "globalincs/vmallocator.h"
+#include "graphics/font.h"
 
 struct object;
 struct cockpit_display;
@@ -133,7 +134,7 @@
 void hud_start_text_flash(const char *txt, int t, int interval = 200);
 
 // convert a string to use mono spaced numbers
-void hud_num_make_mono(char *num_str);
+void hud_num_make_mono(char *num_str, int font_num = FONT1);
 
 // functions for handling hud animations
 void hud_anim_init(hud_anim *ha, int sx, int sy, const char *filename);
Index: code/hud/hudtarget.cpp
===================================================================
--- code/hud/hudtarget.cpp	(revision 9982)
+++ code/hud/hudtarget.cpp	(working copy)
@@ -5674,7 +5674,7 @@
 				delta_y = clip_h;
 			}
 
-			hud_num_make_mono(buf);
+			hud_num_make_mono(buf, font_num);
 
 			if ( Text_alignment ) {
 				gr_get_string_size(&w, &h, buf);
@@ -6018,7 +6018,7 @@
 			// get rid of #
 			end_string_at_first_hash_symbol(ammo_str);
 
-			hud_num_make_mono(ammo_str);
+			hud_num_make_mono(ammo_str, font_num);
 			gr_get_string_size(&w, &h, ammo_str);
 
 			renderString(position[0] + Weapon_pammo_offset_x - w, name_y, EG_NULL, ammo_str);
@@ -6094,7 +6094,7 @@
 	
 		// print out the ammo right justified
 		sprintf(ammo_str, "%d", ammo);
-		hud_num_make_mono(ammo_str);
+		hud_num_make_mono(ammo_str, font_num);
 		gr_get_string_size(&w, &h, ammo_str);
 
 		renderString(position[0] + Weapon_sammo_offset_x - w, name_y, EG_NULL, ammo_str);		
@@ -6454,7 +6454,7 @@
 
 	if (displayed_distance > 0.0f) {
 		sprintf(buf, "%d", fl2i(displayed_distance + 0.5f));
-		hud_num_make_mono(buf);
+		hud_num_make_mono(buf, font_num);
 		gr_get_string_size(&w, &h, buf);	
 	} else {
 		buf[0] = 0;
@@ -6639,7 +6639,7 @@
 		char ammo_str[32];
 
 		sprintf(ammo_str, "%d", ammo);
-		hud_num_make_mono(ammo_str);
+		hud_num_make_mono(ammo_str, font_num);
 
 		if ( Text_align ) {
 			int w, h;
@@ -6877,7 +6877,7 @@
 			// get rid of #
 			end_string_at_first_hash_symbol(ammo_str);
 
-			hud_num_make_mono(ammo_str);
+			hud_num_make_mono(ammo_str, font_num);
 			gr_get_string_size(&w, &h, ammo_str);
 
 			renderString(position[0] + _pammo_offset_x - w, position[1] + text_y_offset, EG_NULL, ammo_str);
@@ -7000,7 +7000,7 @@
 
 		// print out the ammo right justified
 		sprintf(ammo_str, "%d", ammo);
-		hud_num_make_mono(ammo_str);
+		hud_num_make_mono(ammo_str, font_num);
 		gr_get_string_size(&w, &h, ammo_str);
 
 		renderString(position[0] + _sammo_offset_x - w, position[1] + text_y_offset, EG_NULL, ammo_str);
Index: code/hud/hudnavigation.cpp
===================================================================
--- code/hud/hudnavigation.cpp	(revision 9982)
+++ code/hud/hudnavigation.cpp	(working copy)
@@ -15,7 +15,7 @@
 #include "hud/hudtargetbox.h"
 
 
-extern void hud_target_show_dist_on_bracket(int x, int y, float distance);
+extern void hud_target_show_dist_on_bracket(int x, int y, float distance, int font_num);
 extern void draw_brackets_square_quick(int x1, int y1, int x2, int y2, int thick);
 
 /**
Index: code/hud/hudshield.cpp
===================================================================
--- code/hud/hudshield.cpp	(revision 9982)
+++ code/hud/hudshield.cpp	(working copy)
@@ -1046,7 +1046,7 @@
 
 	sprintf(text_integrity, "%d", numeric_integrity);
 	if ( numeric_integrity < 100 ) {
-		hud_num_make_mono(text_integrity);
+		hud_num_make_mono(text_integrity, font_num);
 	}	
 
 	renderString(final_pos[0], final_pos[1], text_integrity);
Index: code/hud/hud.cpp
===================================================================
--- code/hud/hud.cpp	(revision 9982)
+++ code/hud/hud.cpp	(working copy)
@@ -691,7 +691,7 @@
 		char *text = new char[custom_text.size()+1];
 		strcpy(text, custom_text.c_str());
 
-		hud_num_make_mono(text);
+		hud_num_make_mono(text, font_num);
 		renderString(position[0] + textoffset_x, position[1] + textoffset_y, text);
 
 		delete[] text;
@@ -2073,7 +2073,7 @@
 			screen_integrity = 1;
 		}
 		sprintf(buf, XSTR( "%d%%", 219), screen_integrity);
-		hud_num_make_mono(buf);
+		hud_num_make_mono(buf, font_num);
 		gr_get_string_size(&w, &h, buf);
 		if ( screen_integrity < 30 ) {
 			gr_set_color_fast(&Color_red);
@@ -2187,7 +2187,7 @@
 		}
 
 		sprintf(buf, XSTR( "%d%%", 219), best_str);
-		hud_num_make_mono(buf);
+		hud_num_make_mono(buf, font_num);
 		gr_get_string_size(&w, &h, buf);
 		renderString(position[0] + subsys_integ_val_offset_x - w, sy, buf);
 		sy += line_h;
@@ -2311,12 +2311,18 @@
 /**
  * @brief Convert a number string to use mono-spaced 1 character
  */
-void hud_num_make_mono(char *num_str)
+void hud_num_make_mono(char *num_str, int font_num)
 {
-	int len, i, sc;
+	int len, i;
+	ubyte sc;
+
+	sc = lcl_get_font_index(font_num);
+	if (sc == 0) {
+		// specified font has no mono-spaced 1, make do with non-mono-spaced 1
+		return;
+	}
+
 	len = strlen(num_str);
-
-	sc = Lcl_special_chars;
 	for ( i = 0; i < len; i++ ) {
 		if ( num_str[i] == '1' ) {
 			num_str[i] = (char)(sc + 1);
Index: code/hud/hudreticle.cpp
===================================================================
--- code/hud/hudreticle.cpp	(revision 9982)
+++ code/hud/hudreticle.cpp	(working copy)
@@ -502,7 +502,7 @@
 			sprintf(buf, "%d", fl2i(desired_speed * Hud_speed_multiplier + 0.5f));
 		}
 
-		hud_num_make_mono(buf);
+		hud_num_make_mono(buf, font_num);
 		gr_get_string_size(&w, &h, buf);
 
 		renderString(position[0] + Target_speed_offsets[0] - w, position[1] + Target_speed_offsets[1], buf);
@@ -530,7 +530,7 @@
 
 	//setGaugeColor();
 	sprintf(buf, "%d", fl2i(current_speed+0.5f));
-	hud_num_make_mono(buf);
+	hud_num_make_mono(buf, font_num);
 	gr_get_string_size(&w, &h, buf);
 
 	if ( orbit ) {
Index: code/hud/hudbrackets.cpp
===================================================================
--- code/hud/hudbrackets.cpp	(revision 9982)
+++ code/hud/hudbrackets.cpp	(working copy)
@@ -385,7 +385,7 @@
 extern int Cmdline_targetinfo;
 
 // Display the current target distance, right justified at (x,y)
-void hud_target_show_dist_on_bracket(int x, int y, float distance)
+void hud_target_show_dist_on_bracket(int x, int y, float distance, int font_num)
 {
 	char	text_dist[64];
 	int	w,h;
@@ -403,7 +403,7 @@
 	displayed_distance = distance * Hud_unit_multiplier;
 
 	sprintf(text_dist, "%d", fl2i(displayed_distance+0.5f));
-	hud_num_make_mono(text_dist);
+	hud_num_make_mono(text_dist, font_num);
 	gr_get_string_size(&w,&h,text_dist);
 
 	int y_delta = 4;
@@ -877,7 +877,7 @@
 	}
 
 	// draw distance to target in lower right corner of box
-	hud_target_show_dist_on_bracket(x+(box_scale+10),y+(box_scale+10), dist);
+	hud_target_show_dist_on_bracket(x+(box_scale+10),y+(box_scale+10), dist, font_num);
 
 	// bring the scale back to normal
 	gr_reset_screen_scale();
@@ -925,7 +925,7 @@
 
 	// draw distance to target in lower right corner of box
 	if ( distance > 0 ) {
-		hud_target_show_dist_on_bracket(x2+w_correction,y2+h_correction,distance);
+		hud_target_show_dist_on_bracket(x2+w_correction,y2+h_correction,distance,font_num);
 	}
 
 	//	Maybe show + for each additional fighter or bomber attacking target.
Index: code/hud/hudtargetbox.cpp
===================================================================
--- code/hud/hudtargetbox.cpp	(revision 9982)
+++ code/hud/hudtargetbox.cpp	(working copy)
@@ -1113,7 +1113,7 @@
 		hy = fl2i(HUD_offset_y);
 
 		sprintf(outstr,XSTR( "d: %.0f", 340), dist);
-		hud_num_make_mono(outstr);
+		hud_num_make_mono(outstr, font_num);
 		gr_get_string_size(&w,&h,outstr);
 	
 		renderPrintf(position[0] + Dist_offsets[0]+hx, position[1] + Dist_offsets[1]+hy, EG_TBOX_DIST, outstr);
@@ -1806,7 +1806,7 @@
 	// print out the target distance and speed
 	sprintf(outstr,XSTR( "d: %.0f%s", 350), displayed_target_distance, modifiers[Player_ai->current_target_dist_trend]);
 
-	hud_num_make_mono(outstr);
+	hud_num_make_mono(outstr, font_num);
 	gr_get_string_size(&w,&h,outstr);
 
 	renderString(position[0] + Dist_offsets[0]+hx, position[1] + Dist_offsets[1]+hy, EG_TBOX_DIST, outstr);	
@@ -1835,7 +1835,7 @@
 	}
 
 	sprintf(outstr, XSTR( "s: %.0f%s", 351), displayed_target_speed, (displayed_target_speed>1)?modifiers[Player_ai->current_target_speed_trend]:"");
-	hud_num_make_mono(outstr);
+	hud_num_make_mono(outstr, font_num);
 
 	renderString(position[0] + Speed_offsets[0]+hx, position[1] + Speed_offsets[1]+hy, EG_TBOX_SPEED, outstr);
 
Index: code/localization/localize.h
===================================================================
--- code/localization/localize.h	(revision 9982)
+++ code/localization/localize.h	(working copy)
@@ -13,6 +13,7 @@
 #define __FREESPACE2_LOCALIZATION_UTILITIES_HEADER_FILE
 
 #include "globalincs/pstypes.h"
+#include "graphics/font.h"
 
 // ------------------------------------------------------------------------------------------------------------
 // LOCALIZE DEFINES/VARS
@@ -28,7 +29,9 @@
 typedef struct lang_info {
 	char lang_name[LCL_LANG_NAME_LEN + 1];				// literal name of the language
 	char lang_ext[LCL_LANG_NAME_LEN + 1];				// the extension used for adding to names on disk access
-	ubyte special_char_offset;							// where in the font do we have the special characters for this language
+	ubyte special_char_indexes[MAX_FONTS];				// where in the font do we have the special characters for this language
+														// note: treats 0 as "none" since a zero offset in a font makes no sense
+														// i.e. all the normal chars start at zero
 	int checksum;										// used for language auto-detection
 } lang_info;
 
@@ -70,6 +73,8 @@
 // set our current language
 void lcl_set_language(int lang);
 
+// get a fonts special characters index
+ubyte lcl_get_font_index(int font_num);
 
 // NOTE : generally you should only care about the above functions. Below are very low level functions
 //        which should already be well entrenched in FreeSpace. If you think you need to use one of the below
Index: code/localization/localize.cpp
===================================================================
--- code/localization/localize.cpp	(revision 9982)
+++ code/localization/localize.cpp	(working copy)
@@ -29,16 +29,16 @@
 
 // current language
 int Lcl_current_lang = FS2_OPEN_DEFAULT_LANGUAGE;
-SCP_vector<lang_info> Lcl_languages; 
+SCP_vector<lang_info> Lcl_languages;
 
 // These are the original languages supported by FS2. The code expects these languages to be supported even if the tables don't
 
 #define NUM_BUILTIN_LANGUAGES		4
 lang_info Lcl_builtin_languages[NUM_BUILTIN_LANGUAGES] = {
-	{ "English",		"",		127,	589986744},				// English
-	{ "German",			"gr",	164,	-1132430286 },			// German
-	{ "French",			"fr",	164,	0 },					// French
-	{ "Polish",			"pl",	127,	-1131728960},			// Polish
+	{ "English",		"",		{127,0,176,0,0},	589986744},				// English
+	{ "German",			"gr",	{164,0,176,0,0},	-1132430286 },			// German
+	{ "French",			"fr",	{164,0,176,0,0},	0 },					// French
+	{ "Polish",			"pl",	{127,0,176,0,0},	-1131728960},			// Polish
 };
 
 int Lcl_special_chars;
@@ -256,8 +256,17 @@
 			stuff_string(language.lang_name, F_NAME, LCL_LANG_NAME_LEN + 1);
 			required_string("+Extension:");
 			stuff_string(language.lang_ext, F_NAME, LCL_LANG_NAME_LEN + 1);
-			required_string("+Non-English Character Index:");
-			stuff_ubyte(&language.special_char_offset);
+			required_string("+Special Character Index:");
+			stuff_ubyte(&language.special_char_indexes[0]);
+			for (i = 1; i < MAX_FONTS; ++i) {
+				// default to "none"/0 except for font03 which defaults to 176
+				// NOTE: fonts.tbl may override these values
+				if (i == FONT3) {
+					language.special_char_indexes[i] = 176;
+				} else {
+					language.special_char_indexes[i] = 0;
+				}
+			}
 
 			lang_idx = -1;
 
@@ -265,7 +274,7 @@
 			for (i = 0; i < (int)Lcl_languages.size(); i++) {
 				if (!strcmp(Lcl_languages[i].lang_name, language.lang_name)) {
 					strcpy_s(Lcl_languages[i].lang_ext, language.lang_ext); 
-					Lcl_languages[i].special_char_offset = language.special_char_offset;
+					Lcl_languages[i].special_char_indexes[0] = language.special_char_indexes[0];
 					lang_idx = i;
 					break;
 				}
@@ -458,7 +467,7 @@
 	Assertion((Lcl_current_lang >= 0) && (Lcl_current_lang < (int)Lcl_languages.size()), "Attempt to set language to an invalid language");
 
 	// flag the proper language as being active
-	Lcl_special_chars = Lcl_languages[Lcl_current_lang].special_char_offset;
+	Lcl_special_chars = Lcl_languages[Lcl_current_lang].special_char_indexes[0];
 
 	// set to 0, so lcl_ext_open() knows to reset file pointers
 	Lcl_pointer_count = 0;
@@ -469,6 +478,14 @@
 	}
 }
 
+ubyte lcl_get_font_index(int font_num)
+{
+	Assertion((font_num >= 0) && (font_num < MAX_FONTS), "Passed an invalid font index");
+	Assertion((Lcl_current_lang >= 0) && (Lcl_current_lang < (int)Lcl_languages.size()), "Current language is not valid, can't get font indexes");
+
+	return Lcl_languages[Lcl_current_lang].special_char_indexes[font_num];
+}
+
 // maybe add on an appropriate subdirectory when opening a localized file
 void lcl_add_dir(char *current_path)
 {
Index: code/stats/stats.cpp
===================================================================
--- code/stats/stats.cpp	(revision 9982)
+++ code/stats/stats.cpp	(working copy)
@@ -221,7 +221,7 @@
 
          // mission kills stats
 			sprintf(text,"%d",Active_player->stats.kill_count_ok + add.kill_count_ok);
-			hud_num_make_mono(text);
+			hud_num_make_mono(text, gr_get_current_fontnum());
 			gr_printf(sx,sy,text);
 			sy += 2*dy;
          // alltime primary weapon stats
mantis2883-svn.patch (13,767 bytes)   

niffiwan

2013-10-27 03:06

developer   ~0015356

Here's a build with the patch applied: http://www.mediafire.com/?lzz84onr94d5gee

Axem

2013-10-27 12:35

reporter   ~0015357

Looks like its fixed! (For English at least!)

niffiwan

2013-10-28 01:19

developer   ~0015362

Thanks! I'll commit either tonight or tomorrow night.

niffiwan

2013-10-28 05:24

developer   ~0015366

Fix committed to trunk@9985.

Yarn

2014-08-18 20:33

developer   ~0016239

I noticed that, although the monospaced 1 is fixed, the other special characters aren't. This happens because most of the code accesses special characters using offsets form Lcl_special_chars, and that value isn't being changed with the font.

The attached patch fixes this by changing Lcl_special_chars appropriately whenever the font is changed. I also noticed that the copyright info at the bottom of the pilot selection screen uses one of two hardcoded absolute values for the copyright symbol, depending on the language; the patch also fixes this by using an offset from Lcl_special_chars.

Yarn

2014-08-18 20:33

developer  

mantis2883_2.patch (1,257 bytes)   
Index: code/graphics/font.cpp
===================================================================
--- code/graphics/font.cpp	(revision 11009)
+++ code/graphics/font.cpp	(working copy)
@@ -549,11 +549,13 @@
 {
 	if ( fontnum < 0 ) {
 		Current_font = NULL;
+		Lcl_special_chars = 0;
 		return;
 	}
 
 	if ( fontnum >= 0 && fontnum < Num_fonts) {
 		Current_font = &Fonts[fontnum];
+		Lcl_special_chars = lcl_get_font_index(fontnum);
 	}
 }
 
Index: code/menuui/playermenu.cpp
===================================================================
--- code/menuui/playermenu.cpp	(revision 11009)
+++ code/menuui/playermenu.cpp	(working copy)
@@ -1140,11 +1140,7 @@
 
 //	sprintf(Copyright_msg1, NOX("FreeSpace 2"));
 	get_version_string(Copyright_msg1, sizeof(Copyright_msg1));
-	if (Lcl_gr) {
-		sprintf(Copyright_msg2, XSTR("Copyright %c 1999, Volition, Inc.  All rights reserved.", 385), '\xA8');
-	} else {
-		sprintf(Copyright_msg2, XSTR("Copyright %c 1999, Volition, Inc.  All rights reserved.", 385), '\x83');
-	}
+	sprintf(Copyright_msg2, XSTR("Copyright %c 1999, Volition, Inc.  All rights reserved.", 385), Lcl_special_chars + 4);
 
 	gr_get_string_size(&w, NULL, Copyright_msg1);
 	sx = fl2i((gr_screen.max_w_unscaled / 2) - w/2.0f + 0.5f);
mantis2883_2.patch (1,257 bytes)   

niffiwan

2014-08-21 08:45

developer   ~0016245

Fix committed to trunk@11016.

Related Changesets

fs2open: trunk r9767

2013-09-03 08:46

karajorma


Ported: N/A

Details Diff
Fix Mantis 2883 (All the 1's have vanished since r9761) Affected Issues
0002883
mod - /trunk/fs2_open/code/localization/localize.cpp Diff File

fs2open: trunk r9985

2013-10-28 01:48

niffiwan


Ported: N/A

Details Diff
Fix mantis 2883

update hud_num_make_mono (& callers) to handle the font number
add partial support for specifying special char indexes for individual fonts
Affected Issues
0002883
mod - /trunk/fs2_open/code/hud/hud.cpp Diff File
mod - /trunk/fs2_open/code/hud/hud.h Diff File
mod - /trunk/fs2_open/code/hud/hudbrackets.cpp Diff File
mod - /trunk/fs2_open/code/hud/hudnavigation.cpp Diff File
mod - /trunk/fs2_open/code/hud/hudreticle.cpp Diff File
mod - /trunk/fs2_open/code/hud/hudshield.cpp Diff File
mod - /trunk/fs2_open/code/hud/hudtarget.cpp Diff File
mod - /trunk/fs2_open/code/hud/hudtargetbox.cpp Diff File
mod - /trunk/fs2_open/code/localization/localize.cpp Diff File
mod - /trunk/fs2_open/code/localization/localize.h Diff File
mod - /trunk/fs2_open/code/stats/stats.cpp Diff File

fs2open: trunk r11016

2014-08-21 05:15

niffiwan


Ported: N/A

Details Diff
Followup fix for mantis 2883 (from Yarn)

Set Lcl_special_chars when changing fonts
Change some copyright chars to use Lcl_special_chars
Affected Issues
0002883
mod - /trunk/fs2_open/code/menuui/playermenu.cpp Diff File
mod - /trunk/fs2_open/code/graphics/font.cpp Diff File

Issue History

Date Modified Username Field Change
2013-06-02 23:35 Axem New Issue
2013-06-02 23:35 Axem File Added: fonttrouble.jpg
2013-06-06 03:17 Backslash Note Added: 0015120
2013-06-08 12:48 Axem Note Added: 0015123
2013-09-02 13:04 MjnMixael File Added: ImageBin.jpg
2013-09-02 13:05 MjnMixael Note Added: 0015259
2013-09-03 02:33 MjnMixael Note Edited: 0015259
2013-09-03 12:32 karajorma Changeset attached => fs2open trunk r9767
2013-09-03 12:32 karajorma Note Added: 0015264
2013-09-03 12:32 karajorma Status new => resolved
2013-09-03 12:32 karajorma Resolution open => fixed
2013-09-03 21:19 Axem Note Added: 0015266
2013-09-03 21:19 Axem Status resolved => feedback
2013-09-03 21:19 Axem Resolution fixed => reopened
2013-09-12 01:23 niffiwan Note Added: 0015270
2013-09-14 23:08 Yarn Note Added: 0015272
2013-09-17 19:37 Axem File Added: badfonts-hdg.tbm
2013-09-17 19:38 Axem Note Added: 0015275
2013-09-17 19:38 Axem Status feedback => new
2013-09-17 19:39 Axem Note Edited: 0015275
2013-09-17 19:39 Axem Note Edited: 0015275
2013-10-22 03:43 niffiwan Assigned To => niffiwan
2013-10-22 03:43 niffiwan Status new => assigned
2013-10-22 04:08 niffiwan Note Added: 0015344
2013-10-22 05:09 niffiwan Note Edited: 0015344
2013-10-22 06:56 niffiwan Note Edited: 0015344
2013-10-22 06:57 niffiwan Note Edited: 0015344
2013-10-22 06:57 niffiwan Note Edited: 0015344
2013-10-22 11:01 Axem Note Added: 0015345
2013-10-26 23:00 niffiwan File Added: mantis2883-svn.patch
2013-10-26 23:01 niffiwan Note Added: 0015349
2013-10-26 23:01 niffiwan Status assigned => feedback
2013-10-26 23:21 Yarn Note Added: 0015350
2013-10-26 23:29 niffiwan Note Added: 0015351
2013-10-26 23:40 niffiwan File Deleted: mantis2883-svn.patch
2013-10-26 23:40 niffiwan File Added: mantis2883-svn.patch
2013-10-26 23:41 niffiwan Note Edited: 0015351
2013-10-27 00:00 Yarn Note Added: 0015352
2013-10-27 00:16 niffiwan Note Added: 0015353
2013-10-27 00:25 niffiwan Note Edited: 0015353
2013-10-27 00:37 niffiwan Note Edited: 0015353
2013-10-27 00:41 Yarn Note Added: 0015354
2013-10-27 00:54 niffiwan Note Added: 0015355
2013-10-27 01:00 niffiwan File Deleted: mantis2883-svn.patch
2013-10-27 01:00 niffiwan File Added: mantis2883-svn.patch
2013-10-27 01:01 niffiwan Note Edited: 0015355
2013-10-27 03:06 niffiwan Note Added: 0015356
2013-10-27 12:35 Axem Note Added: 0015357
2013-10-27 12:35 Axem Status feedback => assigned
2013-10-28 01:19 niffiwan Note Added: 0015362
2013-10-28 05:24 niffiwan Changeset attached => fs2open trunk r9985
2013-10-28 05:24 niffiwan Note Added: 0015366
2013-10-28 05:24 niffiwan Status assigned => resolved
2014-08-18 20:33 Yarn Note Added: 0016239
2014-08-18 20:33 Yarn Status resolved => feedback
2014-08-18 20:33 Yarn File Added: mantis2883_2.patch
2014-08-18 20:34 Yarn Status feedback => code review
2014-08-21 08:45 niffiwan Changeset attached => fs2open trunk r11016
2014-08-21 08:45 niffiwan Note Added: 0016245
2014-08-21 08:45 niffiwan Status code review => resolved