bugFreeciv - Bugs: bug #19900, Font preferences not respected

 
 
Show feedback again

bug #19900: Font preferences not respected

Submitted by:  Jacob Nevins <jtn>
Submitted on:  Thu 05 Jul 2012 09:22:48 AM UTC  
 
Category: client-gtk-3.0Severity: 3 - Normal
Priority: 5 - NormalStatus: Duplicate
Assigned to: NoneOpen/Closed: Closed
Release: S2_4 r21450Operating System: GNU/Linux
Planned Release: 2.4.0,2.5.0

Add a New Comment (Rich MarkupRich Markup):
   

You are not logged in

Please log in, so followups can be emailed to you.

 

(Jump to the original submission Jump to the original submission)

Sat 19 Jan 2013 03:54:03 PM UTC, comment #10:

> On that note: while it seem ORANGE was never implemented, what
> was its purpose at what should have been its range (simply out
> of curiosity) ?

I've wondered that too.
It looks like, prior to r3896, pollution in the city dialog was 0 => black, 1-9 => "RACE6" (maybe orange?), 10+ => red.

Jacob Nevins <jtn>
Project Administrator
Sat 19 Jan 2013 03:35:54 PM UTC, comment #9:

So, I think:

In any case, my original symptoms no longer show up on an unpatched trunk (r22100) Gtk3 build on a (different) Ubuntu 12.04 machine.

Anything left to do under this ticket?

Jacob Nevins <jtn>
Project Administrator
Mon 27 Aug 2012 01:09:34 AM UTC, comment #8:

I've looked at the patch from comment #7 again and noticed it could be simplified. At the same time I've decided to split it into two parts - one for the font and the other for style unrelated to the font.

A word of explanation about gui_update_font_full: once the three get initialized in ui_main, they can't be NULL - pango_font_description_from_string won't return NULL, at most a NULL filled description.

Patches are against trunk.

(file #16434, file #16435)

Rafał Mużyło <galtgendo>
Thu 26 Jul 2012 08:43:13 PM UTC, comment #7:

Alright, it's hard to affect a tooltip, if it's not really a tooltip.

I was looking at the info popups in city dialog - setting them to monospace makes the formating work again.

(file #16201)

Rafał Mużyło <galtgendo>
Thu 26 Jul 2012 05:53:13 PM UTC, comment #6:

...and for a difference, on a topic related note, a minor fix for help label colors - value taken from old Freeciv.h.

(that line for font in tooltip doesn't seem to work, but the colors do)

(file #16199)

Rafał Mużyło <galtgendo>
Thu 26 Jul 2012 03:58:36 PM UTC, comment #5:

OK, as patch #3433 was merged, it's time to polish this one.

It does what the initial one did and cleans up old API.

It also touches info_label_style in citydialog.c, as while it's not quite topic related, it is API related.

On that note: while it seem ORANGE was never implemented, what was its purpose at what should have been its range (simply out of curiosity) ?

Still thinking about turn button - perhaps I'm wrong and it already works, but an API cleanup there wouldn't be out of place.

(file #16198)

Rafał Mużyło <galtgendo>
Sun 15 Jul 2012 05:58:33 PM UTC, comment #4:

> As such, I'd just like to hear if it does seem to work for
> anybody else.

I confirm it seems to work for me :)

Previously I wrote:

> (This is on Ubuntu Linux 11.04 LTS, BTW.)

Lies! I meant 12.04 (Precise).

Jacob Nevins <jtn>
Project Administrator
Sat 14 Jul 2012 01:09:24 PM UTC, comment #3:

So,...
Following piece of code seems to help, but:
a) I tend to see things
b) it's nowhere near ready to be applied to the tree

As such, I'd just like to hear if it does seem to work for anybody else.

Also, while I could try to separate gtk3-only code from common, if (as noted in a different patch/bug) the current plan is to remove code specific to gtk2, I'd like to see that patch getting in first (preferably by Marko). Then I could do something about cleaning up the code in several places, as this change makes quite a few older solutions (mostly those referring to GtkStyle) redundant.

Unfortunately, unless I'm missing something, blinking turn button is still not working.

(file #16085)

Anonymous
Thu 05 Jul 2012 01:45:53 PM UTC, comment #2:

It's actually not quite a bug - the port is simply a bit incomplete here.
Though even if the table of food/prod/etc doesn't seem misaligned, the tooltips on it seem to be.

It's documented in the upgrade section of gtk3 docs, that gtk_rc_parse_string isn't supposed to work.
Theming was low priority during porting, after all.

gui_update_font_full and gui_update_font will need a fix.

Not sure when I'll get to it.

Anonymous
Thu 05 Jul 2012 09:23:15 AM UTC, comment #1:

(This is on Ubuntu Linux 11.04 LTS, BTW.)

Jacob Nevins <jtn>
Project Administrator
Thu 05 Jul 2012 09:22:48 AM UTC, original submission:

In places where I expect a fixed-width font to be used -- the Spaceship dialog legend, the Demographics report, the tables in the help for Terrain Alterations -- it instead uses a non-fixed-width font, causing the cheesy ASCII tables to be misaligned.

In the city dialog, the table of food/prod/etc is also using a proportional font, but isn't misaligned -- perhaps this has been handled specially?

In the client settings dialog, some relevant font settings are as follows:

  • City Label: Monospace 8
  • Spaceship Label: Monospace 8
  • Help Text: Monospace 10
  • Chatline Area: Monospace 8

(In the font settings panel, different fonts seem to display correctly.)

This is as compiled from svn, so no theme; don't know if that makes a difference. This was the first time I ran it since the settings migration went in, so the settings were freshly copied from the Gtk2 ones.

Jacob Nevins <jtn>
Project Administrator

 

(Note: upload size limit is set to 1024 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

Attached Files
file #16434:  0001-fix-applying-font-style.patch added by galtgendo (7kB - text/x-patch - patch from comment 7, split)
file #16435:  0001-use-GdkRGBA-for-citydlg-labels.patch added by galtgendo (4kB - text/x-patch - patch from comment 7, split)
file #16201:  fix-help-colors.patch added by galtgendo (399B - text/x-patch - better fix for the theme)
file #16199:  fix-help-colors.patch added by galtgendo (319B - text/x-patch - apply colors to help labels)
file #16198:  drop-GtkStyle.patch added by galtgendo (10kB - text/x-patch - polished version of the previous patch)
file #16085:  font-theme-test.patch added by None (921B - text/x-patch - apply fonts to widgets)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by galtgendo (Updated the item)
  • -unavailable- added by jtn (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 9 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Wed 27 Feb 2013 11:53:20 PM UTCjtnStatusNone=>Duplicate
      Open/ClosedOpen=>Closed
    Mon 27 Aug 2012 01:09:34 AM UTCgaltgendoAttached File-=>Added 0001-fix-applying-font-style.patch, #16434
      Attached File-=>Added 0001-use-GdkRGBA-for-citydlg-labels.patch, #16435
    Thu 26 Jul 2012 08:43:12 PM UTCgaltgendoAttached File-=>Added fix-help-colors.patch, #16201
    Thu 26 Jul 2012 05:53:13 PM UTCgaltgendoAttached File-=>Added fix-help-colors.patch, #16199
    Thu 26 Jul 2012 03:58:35 PM UTCgaltgendoAttached File-=>Added drop-GtkStyle.patch, #16198
    Sun 15 Jul 2012 05:58:33 PM UTCjtnSummaryFixed-width font not used=>Font preferences not respected
    Sat 14 Jul 2012 01:09:24 PM UTCNoneAttached File-=>Added font-theme-test.patch, #16085
    Show feedback again

    Back to the top


    Powered by Savane 3.1-cleanup