User:Claus chr/Test1: Difference between revisions
(Created page with "== Test of Input template == <nowiki>{{Input|1=<nowiki>This is verbatim text entered in a template to be displayed as is</ nowiki>}}</nowiki> gives this result {{Inpu...") |
No edit summary |
||
(One intermediate revision by one other user not shown) | |||
Line 11: | Line 11: | ||
entered in a template | entered in a template | ||
to be displayed as is</nowiki>}} | to be displayed as is</nowiki>}} | ||
Similarly the Output template produces | |||
{{Output|1=Some output}} | |||
== Test of the <nowiki><code></nowiki> tag == | == Test of the <nowiki><code></nowiki> tag == | ||
Line 27: | Line 31: | ||
kDebug() << it["r"].uri(); | kDebug() << it["r"].uri(); | ||
} | } | ||
</syntaxhighlight> | |||
shorter approach: | |||
<syntaxhighlight lang="css"> | |||
.com { color: #93a1a1; } | |||
.lit { color: #195f91; } | |||
.pun, .opn, .clo { color: #93a1a1; } | |||
.fun { color: #dc322f; } | |||
.str, .atv { color: #D14; } | |||
.kwd, .linenums .tag { color: #1e347b; } | |||
.typ, .atn, .dec, .var { color: teal; } | |||
.pln { color: #48484c; } | |||
</syntaxhighlight> | </syntaxhighlight> |
Latest revision as of 20:37, 5 January 2013
Test of Input template
{{Input|1=<nowiki>This is verbatim text entered in a template to be displayed as is</ nowiki>}}
gives this result
This is verbatim text entered in a template to be displayed as is
Similarly the Output template produces
Some output
Test of the <code> tag
This snippet <code>short command</code> displayes a short command
in the body of text that encloses it.
Syntaxhighlight
The queries can be run via this model -
QString query = QString::fromLatin1("select ?r where { ?r a nco:Contact . }");
Soprano::Model* model = Nepomuk2::ResourceManager::instance()->mainModel();
Soprano::QueryResultIterator it = model->executeQuery( query, Soprano::Query::QueryLanguageSparql );
while( it.next() ) {
kDebug() << it["r"].uri();
}
shorter approach:
.com { color: #93a1a1; }
.lit { color: #195f91; }
.pun, .opn, .clo { color: #93a1a1; }
.fun { color: #dc322f; }
.str, .atv { color: #D14; }
.kwd, .linenums .tag { color: #1e347b; }
.typ, .atn, .dec, .var { color: teal; }
.pln { color: #48484c; }