Template:Picdic/documentation: Difference between revisions

From The Languages of David J. Peterson
Jump to navigation Jump to search
(Created page with "{{documentation subpage}} Use this template to add a Picture dictionary to an entry. '''Usage''' (see four different ways to use this template below): {{ picdic | image=Solar_sys8.jpg | text=Solar System | width=200 | detail1= {{ picdicimg |en| image=Milky Way Galaxy.jpg | link=heavenly body }} | detail2= {{ picdicimg |en| image=Celestia sun.jpg | link=Sun | altlink=The sun }} {{ picdicimg |en| image=Mercury in color - Prockter07 centered...")
 
m (Changed links to point to Wiktionary)
Line 31: Line 31:
:Image that describes the entry.
:Image that describes the entry.
;detail1
;detail1
: Any content, in most cases clickable image(s) describing a [[hypernym]].
: Any content, in most cases clickable image(s) describing a {{wt|hypernym}}.
: A clickable image can be inserted by adding a line with [[template:picdicimg]] for each image.
: A clickable image can be inserted by adding a line with [[template:picdicimg]] for each image.


Line 38: Line 38:
;detail3
;detail3
;detail4
;detail4
: Any content, in most cases clickable images describing the [[hyponym]]s.
: Any content, in most cases clickable images describing the {{wt|hyponym}}s.
: A clickable image can be inserted by adding a line with [[template:picdicimg]] for each image.
: A clickable image can be inserted by adding a line with [[template:picdicimg]] for each image.
: detail2, detail3 and detail4 are optional, in that case [[hyponym]]s should be described elsewhere.
: detail2, detail3 and detail4 are optional, in that case {{wt|hyponym}}s should be described elsewhere.
: Within parameters detail1, detail2, detail3 and detail4 the full wiki syntax can be used. The only restriction is the use of the <nowiki>|</nowiki> character in tables (and complex templates). That character should be replaced by the template <nowiki>{{!}}</nowiki>. For tables <nowiki>{|, |-, |, ||, |} etc. should be replaced by {{{!}}, {{!}}-, {{!}}, {{!}}{{!}}, {{!}}} etc. </nowiki> Alternatively the [[w:Help:Table#Other_table_syntax|(X)HTML syntax for tables]] can be used like &lt;table>&lt;tr>&lt;td> &lt;/td>&lt;/tr>&lt;/table>.
: Within parameters detail1, detail2, detail3 and detail4 the full wiki syntax can be used. The only restriction is the use of the <nowiki>|</nowiki> character in tables (and complex templates). That character should be replaced by the template <nowiki>{{!}}</nowiki>. For tables <nowiki>{|, |-, |, ||, |} etc. should be replaced by {{{!}}, {{!}}-, {{!}}, {{!}}{{!}}, {{!}}} etc. </nowiki> Alternatively the [[w:Help:Table#Other_table_syntax|(X)HTML syntax for tables]] can be used like &lt;table>&lt;tr>&lt;td> &lt;/td>&lt;/tr>&lt;/table>.
;scrollable
;scrollable
Line 53: Line 53:
:This parameter is optional, the default height is 310.
:This parameter is optional, the default height is 310.
;imagemap
;imagemap
: This parameter is optional, and only to be used in case of an image map instead of other visual content describing the [[hyponym]]s.
: This parameter is optional, and only to be used in case of an image map instead of other visual content describing the {{wt|hyponym}}s.
: The parameter imagemap cannot be used in combination with the parameter labels
: The parameter imagemap cannot be used in combination with the parameter labels
: To use image maps this parameter should be filled with a valid defintion of the imagemap areas.
: To use image maps this parameter should be filled with a valid defintion of the imagemap areas.
Line 60: Line 60:
<div style="font-size:9px; background:#EEEEEE;">
<div style="font-size:9px; background:#EEEEEE;">
::imagemap=
::imagemap=
::<nowiki>circle 1035 572 13 [[Mercury]]</nowiki>
::<nowiki>circle 1035 572 13 {{wt|Mercury}}</nowiki>
::<nowiki>circle 860 483 234 [[Sun]]</nowiki>
::<nowiki>circle 860 483 234 {{wt|Sun}}</nowiki>
</div>
</div>
: A tutorial to use image maps can be found at [[:w:Wikipedia:Wikipedia Signpost/2008-03-03/Tutorial|Wikipedia:Wikipedia Signpost/2008-03-03]].
: A tutorial to use image maps can be found at [[:w:Wikipedia:Wikipedia Signpost/2008-03-03/Tutorial|Wikipedia:Wikipedia Signpost/2008-03-03]].
;labels
;labels
: This parameter is optional, and only to be used in case of text labels to be inserted on the main image instead of other visual content describing the [[hyponym]]s.
: This parameter is optional, and only to be used in case of text labels to be inserted on the main image instead of other visual content describing the {{wt|hyponym}}s.
: The parameter labels cannot be used in combination with the parameter imagemap
: The parameter labels cannot be used in combination with the parameter imagemap
: The labels itself should be inserted by adding a line with [[template:picdiclabel]] for each label.
: The labels itself should be inserted by adding a line with [[template:picdiclabel]] for each label.
Line 78: Line 78:
=== Examples ===
=== Examples ===


Four different ways to use [[Project:Picture dictionary | Picture dictionary]] (using [[Template:picdic]]), [[Solar System]] examples with comparable links.
Four different ways to use [[Project:Picture dictionary | Picture dictionary]] (using [[Template:picdic]]), {{wt|Solar System}} examples with comparable links.
{|
{|
|-
|-

Revision as of 02:18, 25 August 2024

Documentation for Template:Picdic. [edit]
This page contains usage information, categories, interwiki links and other content describing the template.

Use this template to add a Picture dictionary to an entry.

Usage (see four different ways to use this template below):

{{ picdic
| image=Solar_sys8.jpg
| detail1=

{{ picdicimg | image=Milky Way Galaxy.jpg | link=heavenly body |lang=en}}

| detail2=

{{ picdicimg | image=Celestia sun.jpg | link=Sun | altlink=The sun |lang=en}}
{{ picdicimg | image=Mercury in color - Prockter07 centered.jpg | link=Mercury |lang=en}}

}}

Parameters for this template:

image
Image that describes the entry.
detail1
Any content, in most cases clickable image(s) describing a hypernym.
A clickable image can be inserted by adding a line with template:picdicimg for each image.

Optional parameters

detail2
detail3
detail4
Any content, in most cases clickable images describing the hyponyms.
A clickable image can be inserted by adding a line with template:picdicimg for each image.
detail2, detail3 and detail4 are optional, in that case hyponyms should be described elsewhere.
Within parameters detail1, detail2, detail3 and detail4 the full wiki syntax can be used. The only restriction is the use of the | character in tables (and complex templates). That character should be replaced by the template {{!}}. For tables {|, |-, |, ||, |} etc. should be replaced by {{{!}}, {{!}}-, {{!}}, {{!}}{{!}}, {{!}}} etc. Alternatively the (X)HTML syntax for tables can be used like <table><tr><td> </td></tr></table>.
scrollable
Fill scrollable=yes to have a scroll bar at the bottom of the details
text
The name of the entry. The default value is the page name of the entry.
width
Maximum width of the image.
This parameter is optional, the default width is 310.
height
Maximum height of the image.
This parameter is optional, the default height is 310.
imagemap
This parameter is optional, and only to be used in case of an image map instead of other visual content describing the hyponyms.
The parameter imagemap cannot be used in combination with the parameter labels
To use image maps this parameter should be filled with a valid defintion of the imagemap areas.
The coordinates are the number of pixels from the upper-left-hand corner of the default size of the image, so are independent of the size shown on screen.
Example of this parameter:
imagemap=
circle 1035 572 13 {{wt|Mercury}}
circle 860 483 234 {{wt|Sun}}
A tutorial to use image maps can be found at Wikipedia:Wikipedia Signpost/2008-03-03.
labels
This parameter is optional, and only to be used in case of text labels to be inserted on the main image instead of other visual content describing the hyponyms.
The parameter labels cannot be used in combination with the parameter imagemap
The labels itself should be inserted by adding a line with template:picdiclabel for each label.
The coordinates are the number of pixels from the upper-left-hand corner of the visible size of the image, so are dependent of the size shown on screen. See the template for further info.
Examples of this parameter:
labels=
{{ picdiclabel | posx=181 | posy= 86 | link=Sun |lang=en}}
{{ picdiclabel | posx=214 | posy=119 | link=Mercury | style="text-align:right;" |lang=en}}

Examples

Four different ways to use Picture dictionary (using Template:picdic), Solar System examples with comparable links.

Picture dictionary with clickable images

Picture dictionary with legend and wikilinks

Picture dictionary with image map

Picture dictionary with labels

Code:

{{ picdic
| image=Solar_sys8.jpg
| detail1=

{{ picdicimg | image=Milky Way Galaxy.jpg | link=heavenly body |lang=en}}

| detail2=

{{ picdicimg | image=Celestia sun.jpg | link=Sun | altlink=The sun |lang=en}}
{{ picdicimg | image=Mercury in color - Prockter07 centered.jpg | link=Mercury |lang=en}}
etc.

}}

Code:

{{ picdic
| image=Solar sys8 numbered.jpg
| detail1=

{{ picdicimg | image=Milky Way Galaxy.jpg | link=heavenly body |lang=en}}

| detail2=

'''Legend (1):'''<br/>
1= [[Sun#English | The sun]]
2= [[Mercury#English | Mercury]]
3= etc

}}

Code:

{{ picdic
| image=Solar_sys8.jpg
| imagemap=

circle 1035 572 13 [[Mercury#English | Mercury]]
circle 860 483 234 [[Sun#English | The sun]]
etc

| detail1=Click on parts of the image
| detail2=

{{ picdicimg | image=Milky Way Galaxy.jpg | link=heavenly body |lang=en}}

}}

Code:

{{ picdic
| image=Solar_sys8.jpg
| width=310
| labels=

{{ picdiclabel | color=white | fontsize=18 | posx=181 | posy= 86 | link=Sun | altlink=The sun |lang=en}}
{{ picdiclabel | color=white | fontsize=12 | posx=214 | posy=119 | link=Mercury | style="text-align:right;" |lang=en}}
etc.

| detail1=Click on labels in the image
| detail2=

{{ picdicimg | image=Milky Way Galaxy.jpg | link=heavenly body |lang=en}}

}}

simple:Template:picdic