patchFreeciv - Patches: patch #3361, Support web-links in helptexts

 
 
Show feedback again

patch #3361: Support web-links in helptexts

Submitted by:  Marko Lindqvist <cazfi>
Submitted on:  Tue 03 Jul 2012 10:32:31 PM UTC  
 
Category: NonePriority: 5 - Normal
Status: NonePrivacy: Public
Assigned to: NoneOpen/Closed: Open
Planned Release: 

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)

Mon 26 May 2014 03:04:22 PM UTC, comment #6:

One of the things I want to do with this is to improve the situation for ruleset entities who have a relationship linked by unit flags, tech flags or similar -- potentially a many-to-many relationship.

Currently, if some building enables units with a particular flag or property, when autogenerating help we've an unsatisfactory choice:

  • list all units with the flag (potentially an unreadably long list)
  • a cop-out like "Settlers and similar units" leaving the player to guess what 'similar' means
  • explicitly saying "units with the 'AirUnit' flag"; the flag name may not be intended for human eyes or translateable, and players have to scrub through all the units to find out which ones have the 'AirUnit' flag.

We currently use a mix of these.

If we had hyperlinks, the unit flag name could be a hyperlink taking you to a report which lists all the units which have flag, and possibly other entities to which it's relevant. Same goes for anything that divides entities into sets (unit classes, tech flags, etc).

Jacob Nevins <jtn>
Project Administrator
Thu 18 Jul 2013 05:50:20 PM UTC, comment #5:

I've found: https://developer.gnome.org/pango/unstable/index.html and https://developer.gnome.org/pango/unstable/PangoMarkupFormat.html

J. M. Gorbach <gorb>
Sun 15 Jul 2012 01:39:52 PM UTC, comment #4:

Yes, BBcode or similar is about the level of markup we need.

I doubt we'd import code to do it (especially not .NET/C#/C++ code), I'm mostly looking for ideas.

Of course we already have our own minilanguage, the "featured text" used in the chatline. But the emphasis is slightly different from what we need for the help (we won't need colour or links to specific units, for instance).

Another requirement I forgot:

  • bulletted lists
Jacob Nevins <jtn>
Project Administrator
Fri 06 Jul 2012 07:06:10 PM UTC, comment #3:

Maybe this library is useful:
http://sourceforge.net/projects/bbcodelib/

J. M. Gorbach <gorb>
Fri 06 Jul 2012 04:46:11 PM UTC, comment #2:

Perhaps there could be a backport of bbcode to C99? Looking at bbcode.org I see that there are .NET and C# implementations one of those could possibly be ported quite easily. As I read though, it seems that it functions by transforming to html. It's more of a security feature to avoid arbitrary code. Implementing a reasonable subset for our own purposes should pretty straightforward. Also, many people already know it that aren't programmers.

Zakri Kneebone <i1abnrk>
Thu 05 Jul 2012 09:30:10 PM UTC, comment #1:

I've been thinking for a while that I'd like some sort of markup language for the help system. It's a big project, though.

My initial thoughts on requirements:

  • Deliberately simple. Not HTML+CSS, I don't want Freeciv dependent on something that heavyweight, and it's overkill for us.
    • If there's an existing deliberately-simple markup that's about the right shape, we can use it, but I suspect we'll end up inventing our own.
  • Supports simple formatting (bold, italic, headings)
  • Supports hyperlinks
    • Both within the help system ("see the section on Terrain") and external. Latter is easier.
  • Some way of including some kinds of images
    • For instance, the help on cities could really use a city map. Ideally it would be rendered on the fly with the current tileset, but it's hard to see how to do that in a ruleset-independent way, so it'll probably have to be a screenshot.
  • (Simple) tables
  • GUI-independent (drives simplicity requirement -- capabilities need to be subset of intersection of what's easily achievable with all current and likely GUIs)
    • Should be renderable to cheesy ASCII fallback, giving output not too far from what we have now, so we don't have to upgrade every client at once (or ever, so we're not restricted by for example what's easy to implement in Xaw or SDL)
Jacob Nevins <jtn>
Project Administrator
Tue 03 Jul 2012 10:32:31 PM UTC, original submission:

In recent discussion it was proposed that nation legends should have links to relevant wiki pages. Now it's also requested that helptexts (of techs) could contain links.

Another place where I'd want to see clickable links supported is server connectmsg dialog. Back when I run public server on cazfi.net, my connectmsg had URL to usage instructions (of modpack in use - most importantly where to get compatible tileset for your client), but one had to copypaste it manually to web browser.

Marko Lindqvist <cazfi>
Project Administrator

 

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

Attach File(s):
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by gorb (Posted a comment)
  • -unavailable- added by i1abnrk (Posted a comment)
  • -unavailable- added by jtn (Posted a comment)
  • -unavailable- added by cazfi (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):

     

     

    No Changes Have Been Made to This Item
    Show feedback again

    Back to the top


    Powered by Savane 3.1-cleanup