0 votes
by (260 points)
edited by
In Twine 1 with Sugarcube2

How do I alter the color of links in the left UI (default) from the default blue?

Specifically, I want to be able to make my Story Title/Subtitle etc into links, just not blue ones.

I'm assuming this can be done in my Stylesheet.

.passage a {
    /* This affects passage links */

So what affects what I need?

1 Answer

0 votes
by (68.6k points)
selected by
 
Best answer

First.  The story title should be the project's plain text title and contain no markup.  Most certainly you should never attempt to introduce any kind of dynamism directly into the story title.  SugarCube uses the story's title as part of its storage keys, so adding markup and/or altering the story title during play can result in loss of player data.  That said, you can still achieve your goal of styling the visible title in the UI bar by using a different special passage—there are several in that space which are normally unused; e.g. StoryBanner.  For example:

/*
	Style the story banner similarly to the story title, so that
	the former may be used as a marked up version of the latter.
*/
#story-banner {
	font-size: 162.5%;
	font-weight: bold;
	margin: 0;
}
#story-title {
	display: none;
}

 

As to how to change the colors of anchors within the #story-* elements of the UI bar, just use the appropriate selectors.  Each of the special passages which map to elements within the UI bar do make note of their element's IDs—see: Special Names > Passage Names.  The HTML document also shows the elements.  For example, to change the at-rest color of anchors within the elements corresponding to the StoryBanner, StorySubtitle, StoryAuthor, and StoryCaption special passages:

#story-banner a,
#story-subtitle a,
#story-author a,
#story-caption a {
	color: pink;
}

NOTE: The above example changes the elements as group.  You may change them individually if you wished to apply different style properties to each.

 

by (260 points)
edited by
Thanks, TME. I've got what I wanted sorting but there seems to be plenty more in this area for me to learn cos I'm blagging it a bit atm. :)
...