You are here: Home » Tutorials » Tips-Tricks » JCross: Center thy Clues

JCross: Center thy Clues

Posted by Stan Bogdanov on 07 November 2009 - 16:33

Introduction

Time for another small enhancement.

Clues in a JCross crossword in HotPotatoes come left-aligned. It surely is a little more stylish to have them centered above the crossword grid.

Here are some samples from the Taxonomy, under the 'Crossword' section, of what we're trying to achieve. Visit these exercises and click on a clue, especially the ones both across and down.
· Regular, just plain text crossword · Image Crossword · Audio Crossword.

So, here's how to center the clues in two easy steps.

Step 1 - Create your crossword.htm web page

Step 2 - Edit some CSS

Open the output .htm file in a text/HTML editor and find the CSS part. Look for a chunk of code saying:
div#ClueEntry{
Change it to look like this:
div#ClueEntry{
        font-family: Verdana,Geneva,Arial;
	font-size: 10pt;
	margin-bottom: 1em;
       /* Centered clues */
        text-align: center;
	margin-right:auto;
	margin-left:auto;
	display:block;
	
}

Save, preview, enjoy! And come back for more tips and trick.
You may also want to see the Audio Crossword Tutorials (Beginner and Advanced).

Related tutorials:




Rate this:

  • Currently3.08550724638/5 Stars
  • 1
  • 2
  • 3
  • 4
  • 5
Votes: 690

Share it:

              Windows Live

Write a comment

  • Required fields are marked with *.

If you have trouble reading the code, click on the code itself to generate a new random code.
Security Code:
 

Feedback Form
Feedback Analytics