Documentation
This commit is contained in:
1 parent
8e824083a2
commit
d47d2ce52f
5 files changed
+91
-20
No files matched your search
@@ -6,6 +6,7 @@ incomplete concrete DocumentationRusFunctor of Documentation = CatRus ** open
|
||||
ParadigmsRus,
|
||||
(G = GrammarRus),
|
||||
(S = SyntaxRus),
|
||||
(ST = StructuralRus),
|
||||
(L = LexiconRus),
|
||||
Prelude,
|
||||
HTML
|
||||
@@ -38,7 +39,9 @@ lin
|
||||
heading2 (heading masculine_Parameter) ++
|
||||
inflNoun (makeNFFromAF adj Masc Inanimate) ++
|
||||
heading2 (heading neuter_Parameter) ++
|
||||
inflNoun (makeNFFromAF adj Neut Inanimate)
|
||||
inflNoun (makeNFFromAF adj Neut Inanimate) ++
|
||||
heading2 (heading comparative_Parameter) ++
|
||||
frameTable (tr (tr (adj.comp)))
|
||||
} ;
|
||||
|
||||
InflectionAdv adv = {
|
||||
@@ -84,14 +87,14 @@ lin
|
||||
InflectionV2S v = {
|
||||
t = "v" ;
|
||||
s1 = heading1 (heading verb_Category) ++
|
||||
paragraph (verbExample (S.mkCl S.she_NP v S.we_NP (lin S (ss "...")))) ;
|
||||
paragraph (verbExample (S.mkCl S.she_NP v S.we_NP (lin S {s : Mood=>Str = \\m=>"..."}))) ;
|
||||
s2 = inflVerb v
|
||||
} ;
|
||||
|
||||
InflectionV2Q v = {
|
||||
t = "v" ;
|
||||
s1 = heading1 (heading verb_Category) ++
|
||||
paragraph (verbExample (S.mkCl S.she_NP v S.we_NP (lin QS (ss "...")))) ;
|
||||
paragraph (verbExample (S.mkCl S.she_NP v S.we_NP (lin QS {s: QForm=>Str = \\m=>"..."}))) ;
|
||||
s2 = inflVerb v
|
||||
} ;
|
||||
|
||||
@@ -102,24 +105,24 @@ lin
|
||||
s2 = inflVerb v
|
||||
} ;
|
||||
|
||||
InflectionVV v = {
|
||||
InflectionVV vv = {
|
||||
t = "v" ;
|
||||
s1 = heading1 (heading verb_Category) ++
|
||||
paragraph (verbExample (S.mkCl S.she_NP v (S.mkVP (L.sleep_V)))) ;
|
||||
s2 = inflVerb v
|
||||
paragraph (verbExample (S.mkCl S.she_NP vv (S.mkVP (L.sleep_V)))) ;
|
||||
s2 = inflVerb vv.v
|
||||
} ;
|
||||
|
||||
InflectionVS v = {
|
||||
t = "v" ;
|
||||
s1 = heading1 (heading verb_Category) ++
|
||||
paragraph (verbExample (S.mkCl S.she_NP v (lin S (ss "...")))) ;
|
||||
paragraph (verbExample (S.mkCl S.she_NP v (lin S {s : Mood=>Str = \\m=>"..."}))) ;
|
||||
s2 = inflVerb v
|
||||
} ;
|
||||
|
||||
InflectionVQ v = {
|
||||
t = "v" ;
|
||||
s1 = heading1 (heading verb_Category) ++
|
||||
paragraph (verbExample (S.mkCl S.she_NP v (lin QS (ss "...")))) ;
|
||||
paragraph (verbExample (S.mkCl S.she_NP v (lin QS {s : Mood=>Str = \\m=>"..."}))) ;
|
||||
s2 = inflVerb v
|
||||
} ;
|
||||
|
||||
@@ -134,8 +137,59 @@ oper
|
||||
verbExample : CatRus.Cl -> Str = \cl -> (S.mkUtt cl).s ;
|
||||
{-
|
||||
-} --# notpresent
|
||||
inflVerb : CatRus.V -> Str = \verb0 ->
|
||||
verb0.inf ; -- TODO: make documentation
|
||||
inflVerb : CatRus.V -> Str = \v ->
|
||||
let fut : Agr=>Str = \\a => verbFutAgree v a in
|
||||
let pres : Agr=>Str = \\a => verbPresAgree v a in
|
||||
let past : Agr=>Str = \\a => (verbPastAgree v a "").p2 in
|
||||
let imp : Agr=>Str = \\a => ((verbImperativeAgree v a).p1 ++ (verbImperativeAgree v a).p2) in
|
||||
let ppp : GenNum=>Str = \\gn => shortPastPassPart v gn in
|
||||
case v.asp of {Imperfective => "несовершенного вида" ; Perfective => "совершенного вида"} ++ "," ++
|
||||
case v.refl of {Reflexive => "возвратный" ; NonReflexive => "невозвратный"} ++ "," ++
|
||||
case v.tran of {intransitive => "непереходный" ; Transitive => "переходный"} ++ "," ++
|
||||
heading2 (heading infinitive_Parameter) ++
|
||||
frameTable (
|
||||
tr (td v.inf ++ td v.infrefl)
|
||||
) ++
|
||||
frameTable (
|
||||
tr (th (heading person_ParameterType) ++ th (heading number_ParameterType) ++ th (heading gender_ParameterType)
|
||||
++ th (heading past_Parameter) ++ th (heading present_Parameter) ++ th (heading future_Parameter) ++ th (heading imperative_Parameter)) ++
|
||||
tr (th (heading person1_Parameter) ++ th (heading singular_Parameter) ++ th (heading masculine_Parameter)
|
||||
++ td (past ! Ag (GSg Masc) P1) ++ td (pres ! Ag (GSg Masc) P1) ++ td(fut ! Ag (GSg Masc) P1) ++ td (imp ! Ag (GSg Masc) P1)) ++
|
||||
tr (th "" ++ th "" ++ th (heading feminine_Parameter)
|
||||
++ td (past ! Ag (GSg Fem) P1) ++ td "" ++ td "") ++
|
||||
tr (th "" ++ th "" ++ th (heading neuter_Parameter)
|
||||
++ td (past ! Ag (GSg Neut) P1) ++ td "" ++ td "") ++
|
||||
tr (th "" ++ th (heading plural_Parameter) ++ th ""
|
||||
++ td (past ! Ag GPl P1) ++ td (pres ! Ag GPl P1) ++ td(fut ! Ag GPl P1) ++ td (imp ! Ag GPl P1)) ++
|
||||
tr (th (heading person2_Parameter) ++ th (heading singular_Parameter) ++ th (heading masculine_Parameter)
|
||||
++ td (past ! Ag (GSg Masc) P2) ++ td (pres ! Ag (GSg Masc) P2) ++ td (fut ! Ag (GSg Masc) P2) ++ td (imp ! Ag (GSg Masc) P2) ) ++
|
||||
tr (th "" ++ th "" ++ th (heading feminine_Parameter)
|
||||
++ td (past ! Ag (GSg Fem) P2) ++ td "" ++ td "") ++
|
||||
tr (th "" ++ th "" ++ th (heading neuter_Parameter)
|
||||
++ td (past ! Ag (GSg Neut) P2) ++ td "" ++ td "") ++
|
||||
tr (th "" ++ th (heading plural_Parameter) ++ th ""
|
||||
++ td (past ! Ag GPl P2) ++ td (pres ! Ag GPl P2) ++ td(fut ! Ag GPl P2) ++ td (imp ! Ag GPl P2)) ++
|
||||
tr (th (heading person3_Parameter) ++ th (heading singular_Parameter) ++ th (heading masculine_Parameter)
|
||||
++ td (past ! Ag (GSg Masc) P3) ++ td (pres ! Ag (GSg Masc) P3) ++ td(fut ! Ag (GSg Masc) P3) ) ++
|
||||
tr (th "" ++ th "" ++ th (heading feminine_Parameter)
|
||||
++ td (past ! Ag (GSg Fem) P3) ++ td "" ++ td "") ++
|
||||
tr (th "" ++ th "" ++ th (heading neuter_Parameter)
|
||||
++ td (past ! Ag (GSg Neut) P3) ++ td "" ++ td "") ++
|
||||
tr (th "" ++ th (heading plural_Parameter) ++ th ""
|
||||
++ td (past ! Ag GPl P3) ++ td (pres ! Ag GPl P3) ++ td (fut ! Ag GPl P3) ++ td (imp ! Ag GPl P3) )
|
||||
) ++
|
||||
heading2 ("краткие причастия прошедшего времени") ++
|
||||
frameTable (
|
||||
tr (th (heading masculine_Parameter) ++ th (heading feminine_Parameter) ++ th (heading neuter_Parameter)
|
||||
++ th (heading plural_Parameter)) ++
|
||||
tr (td (ppp ! (GSg Masc)) ++ td (ppp ! (GSg Fem)) ++ td (ppp ! (GSg Neut)) ++ td (ppp ! GPl))
|
||||
) ++
|
||||
heading2 ("деепричастия") ++
|
||||
frameTable (
|
||||
tr (th (heading past_Parameter) ++ th (heading present_Parameter)) ++
|
||||
tr (td (v.prtr ++ verbRefl v) ++ td (v.ptr ++ verbRefl v))
|
||||
)
|
||||
;
|
||||
|
||||
inflNoun : NounForms -> Str = \nf ->
|
||||
frameTable (
|
||||
@@ -144,8 +198,8 @@ oper
|
||||
tr (th (heading genitive_Parameter) ++ td (nf.sgen) ++ td (nf.pgen)) ++
|
||||
tr (th (heading dative_Parameter) ++ td (nf.sdat) ++ td (nf.pdat)) ++
|
||||
tr (th (heading accusative_Parameter) ++ td (nf.sacc) ++ td (nf.pacc)) ++
|
||||
tr (th ("творительный") ++ td (nf.sacc) ++ td (nf.pacc)) ++
|
||||
tr (th ("предложный") ++ td (nf.sacc) ++ td (nf.pacc)) ++
|
||||
tr (th ("творительный") ++ td (nf.sins) ++ td (nf.pins)) ++
|
||||
tr (th ("предложный") ++ td (nf.sprep) ++ td (nf.pprep)) ++
|
||||
tr (th (heading partitive_Parameter) ++ td (nf.sptv) ++ td ("-")) ++
|
||||
tr (th ("местный") ++ td (nf.sloc) ++ td ("-")) ++
|
||||
tr (th ("звательный") ++ td (nf.svoc) ++ td ("-"))
|
||||
@@ -153,8 +207,8 @@ oper
|
||||
|
||||
lin
|
||||
NoDefinition t = {s=t.s};
|
||||
MkDefinition t d = {s="<p><b>Определение:</b>"++t.s++d.s++"</p>"};
|
||||
MkDefinitionEx t d e = {s="<p><b>Определение:</b>"++t.s++d.s++"</p><p><b>Пример:</b>"++e.s++"</p>"};
|
||||
MkDefinition t d = {s="<p><b>" ++ (heading formGr_N) ++ "</b>"++t.s++d.s++"</p>"};
|
||||
MkDefinitionEx t d e = {s="<p><b>" ++ (heading formGr_N) ++ "</b>"++t.s++d.s++"</p><p><b>" ++ (heading exampleGr_N) ++":</b>"++e.s++"</p>"};
|
||||
|
||||
lin
|
||||
MkDocument d i e = ss (i.s1 ++ d.s ++ i.s2 ++ paragraph e.s) ; -- explanation appended in a new paragraph
|
||||
|
||||
@@ -19,7 +19,8 @@ concrete ExtendRus of Extend =
|
||||
|
||||
--ConjRNP, ConjVPS, ConsVPS, Cons_nr_RNP, Cons_rr_RNP, DetNPMasc, DetNPFem, EmbedPresPart, EmptyRelSlash,
|
||||
ExistsNP,
|
||||
-- ExistCN, ExistMassCN, ExistPluralCN, ProDrop,
|
||||
-- ExistCN, ExistMassCN, ExistPluralCN,
|
||||
ProDrop,
|
||||
-- FocusAP, FocusAdV, FocusAdv, FocusObj, GenIP, GenModIP, GenModNP, GenNP, GenRP,
|
||||
-- GerundAdv, GerundCN, GerundNP, IAdvAdv, ICompAP,
|
||||
InOrderToVP,
|
||||
@@ -73,4 +74,12 @@ lin
|
||||
youFem_Pron = personalPron (Ag (GSg Fem) P2) ;
|
||||
|
||||
CompoundN n1 n2 = mkCompoundN n1 "-" n2 ;
|
||||
|
||||
-- : Pron -> Pron ; -- unstressed subject pronoun becomes empty: "am tired"
|
||||
ProDrop pron = {
|
||||
nom,gen,dat,acc,ins,prep=[] ;
|
||||
nPrefix=False ;
|
||||
poss={msnom,fsnom,nsnom,pnom,msgen,fsgen,pgen,msdat,fsacc,msins,fsins,pins,msprep=[]} ;
|
||||
a=pron.a
|
||||
} ;
|
||||
} ;
|
||||
@@ -3,8 +3,8 @@
|
||||
concrete LangRus of Lang =
|
||||
GrammarRus,
|
||||
LexiconRus,
|
||||
ConstructionRus --,
|
||||
--DocumentationRus
|
||||
ConstructionRus,
|
||||
DocumentationRus
|
||||
** {
|
||||
|
||||
flags startcat = Phr ; unlexer = text ; lexer = text ; coding=utf8 ;
|
||||
|
||||
@@ -707,10 +707,10 @@ oper
|
||||
|
||||
verbImperativeAgree : VerbForms -> Agr -> TempParts
|
||||
= \vf,a -> case a of {
|
||||
Ag (GSg _) P1 => <"давайте", (verbInf vf)> ; -- ?
|
||||
Ag (GSg _) P1 => <"", (verbInf vf)> ; -- ?
|
||||
Ag (GSg _) P2 => <"", case vf.refl of {NonReflexive=>vf.isg2; Reflexive=>vf.isg2refl}> ;
|
||||
Ag (GSg x) P3 => <"пусть", verbFutAgree vf (Ag (GSg x) P3)> ; -- ?
|
||||
Ag GPl P1 => <"", vf.ipl1> ;
|
||||
Ag GPl P1 => <"", vf.ipl1 ++ verbReflAfterConsonant vf> ;
|
||||
Ag GPl P2 => <"", vf.isg2 ++ BIND ++ "те" ++ (verbRefl vf)> ;
|
||||
Ag GPl P3 => <"пусть", verbFutAgree vf (Ag GPl P3)>
|
||||
} ;
|
||||
|
||||
@@ -79,6 +79,14 @@ lin
|
||||
negative_Parameter = mkN "отрицательное" ;
|
||||
positivePol_Parameter = mkN "утвердительное" ;
|
||||
|
||||
gender_ParameterType = mkN "род" ;
|
||||
number_ParameterType = mkN "число" ;
|
||||
person_ParameterType = mkN "лицо" ;
|
||||
|
||||
person1_Parameter = mkN "1 л." ;
|
||||
person2_Parameter = mkN "2 л." ;
|
||||
person3_Parameter = mkN "3 л." ;
|
||||
|
||||
long_Parameter = mkN "длинная" ;
|
||||
short_Parameter = mkN "краткая" ;
|
||||
|
||||
@@ -87,7 +95,7 @@ lin
|
||||
nounHeading n = ss n.snom ;
|
||||
nounPluralHeading n = ss n.pnom ;
|
||||
|
||||
formGF_N = mkN "форма" ;
|
||||
formGr_N = mkN "форма" ;
|
||||
exampleGr_N = mkN "пример" ;
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user