Bản mẫu:Sets taxobox colour/doc
![]() | Đây là một trang con tài liệu sử dụng bản mẫu dành cho Bản mẫu:Sets taxobox colour. Nó gồm có các thông tin hướng dẫn sử dụng, thể loại và các nội dung khác không thuộc về phần trang bản mẫu gốc. |
Mục đích
sửa{{Sets taxobox colour}} is a utility template for use in conjunction with taxobox templates (i.e. those that process templates with names of the form "Template:Taxonomy/..."). It checks whether its argument, which should be a taxon name, has a taxobox colour defined in {{Taxobox colour}} but is not "incertae sedis". If this condition is true, it returns the taxon name, otherwise it returns blank.
Assumption
sửaThe template assumes that colours defined in {{Taxobox colour}} use the format rgb(..,..,..)
.
Cách sử dụng
sửaThe template should only be used from within other taxobox templates.
{{Sets taxobox colour|taxon_name}}
It returns the taxon name if the condition is met, otherwise blank.
Các ví dụ
sửa- {{Sets taxobox colour|Animalia}} → Animalia,
- A taxobox colour is explicitly defined for Animalia.
- {{Sets taxobox colour|plantae}} → plantae,
- The taxon name can have an initial capital or not.
- {{Sets taxobox colour|Acacia}} →
- Although Acacia is a plant genus, the taxobox colour is not explicitly defined in {{Taxobox colour}}; in an actual taxobox it is set by determining that Acacia is a member of Plantae.
- {{Sets taxobox colour|incertae sedis}} →
- Although "incertae sedis" has a taxobox colour defined in {{Taxobox colour}}, it is ignored. (This is so that templates that use this one can continue to look higher up the taxonomic hierarchy to see if there is a more appropriate colour; an incertae sedis family, for example, may be known to be an animal, when the Animalia colour should be used.)