3 /** Slovenian (Slovenščina)
7 class LanguageSl
extends Language
{
8 # Convert from the nominative form of a noun to some other case
9 # Invoked with {{GRAMMAR:case|word}}
11 * Cases: rodilnik, dajalnik, tožilnik, mestnik, orodnik
18 function convertGrammar( $word, $case ) {
19 global $wgGrammarForms;
20 if ( isset( $wgGrammarForms['sl'][$case][$word] ) ) {
21 return $wgGrammarForms['sl'][$case][$word];
25 case 'mestnik': # locative
26 $word = 'o ' . $word; break;
27 case 'orodnik': # instrumental
31 return $word; # this will return the original value for 'imenovalnik' (nominativ) and all undefined case values
40 function convertPlural( $count, $forms ) {
41 if ( !count( $forms ) ) { return ''; }
42 $forms = $this->preConvertPlural( $forms, 5 );
44 if ( $count %
100 == 1 ) {
46 } elseif ( $count %
100 == 2 ) {
48 } elseif ( $count %
100 == 3 ||
$count %
100 == 4 ) {
50 } elseif ( $count != 0 ) {
55 return $forms[$index];