-
Notifications
You must be signed in to change notification settings - Fork 51
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
added documentaion and missing paradigm functions
- Loading branch information
Showing
6 changed files
with
520 additions
and
465 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,113 @@ | ||
--# -path=.:../abstract:../common | ||
|
||
concrete DocumentationIna of Documentation = CatIna ** open | ||
ResIna, | ||
Prelude, | ||
HTML | ||
in { | ||
flags coding=utf8 ; | ||
|
||
|
||
lincat | ||
Inflection = {t : Str; s1,s2 : Str} ; | ||
Definition = {s : Str} ; | ||
Document = {s : Str} ; | ||
Tag = {s : Str} ; | ||
|
||
{- | ||
-} --# notpresent | ||
|
||
lin | ||
InflectionN, InflectionN2, InflectionN3 = \noun -> { | ||
t = "s" ; | ||
s1 = heading1 "Substantivo" ; | ||
s2 = frameTable ( | ||
tr (th "Singular" ++ th "Plural") ++ | ||
tr (td (noun.s ! Sg) ++ td (noun.s ! Pl)) | ||
) | ||
} ; | ||
|
||
InflectionPN = \pn -> { | ||
t = "pn" ; | ||
s1 = heading1 ("Nombre Proprio") ; | ||
s2 = pn.s | ||
} ; | ||
|
||
InflectionGN = \gn -> { | ||
t = "pn" ; | ||
s1 = heading1 ("Nombre de Pila" ++ | ||
case gn.g of { | ||
Male => "(Mascule)" ; | ||
Female => "(Femina)" | ||
}) ; | ||
s2 = gn.s | ||
} ; | ||
|
||
InflectionSN = \sn -> { | ||
t = "sn" ; | ||
s1 = heading1 "Apellido" ; | ||
s2 = sn.s ! Male | ||
} ; | ||
|
||
InflectionLN = \ln -> { | ||
t = "nl" ; | ||
s1 = heading1 ("Nombre del Lugar") ; | ||
s2 = paragraph ln.s | ||
} ; | ||
|
||
InflectionA, InflectionA2 = \adj -> { | ||
t = "a" ; | ||
s1 = heading1 "Adjectivo" ; | ||
s2 = paragraph (adj.s ! AAdj Posit) | ||
} ; | ||
|
||
InflectionAdv, InflectionAdV, InflectionAdA, InflectionAdN = \adv -> { | ||
t = "adv" ; | ||
s1 = heading1 "Adverbio" ; | ||
s2 = paragraph adv.s | ||
} ; | ||
|
||
InflectionPrep p = { | ||
t = "prep" ; | ||
s1 = heading1 "Preposition" ; | ||
s2 = paragraph p.s | ||
} ; | ||
|
||
InflectionV, InflectionV2, InflectionV3, InflectionV2V, InflectionV2S, InflectionV2Q, InflectionV2A, InflectionVV, InflectionVS, InflectionVQ, InflectionVA = \v -> { | ||
t = "v" ; | ||
s1 = heading1 "Verbo" ; | ||
s2 = inflVerb v | ||
} ; | ||
|
||
lin | ||
NoDefinition t = {s=t.s}; | ||
MkDefinition t d = {s="<p><b>Definición:</b>"++t.s++d.s++"</p>"}; | ||
MkDefinitionEx t d e = {s="<p><b>Definición:</b>"++t.s++d.s++"</p><p><b>Ejemplo:</b>"++e.s++"</p>"}; | ||
|
||
lin | ||
MkDocument b i e = ss (i.s1 ++ "<p style=\"font-size:20px\">"++b.s++"</p>" ++ i.s2 ++ paragraph e.s) ; -- explanation appended in a new paragraph | ||
MkTag i = ss i.t ; | ||
|
||
oper | ||
inflVerb : Verb -> Str = \verb -> | ||
frameTable ( | ||
tr (th "infinitivo" ++ | ||
td (verb.s ! VInf)) ++ | ||
tr (th "presente" ++ | ||
td (verb.s ! VPres)) ++ | ||
tr (th "participio passato" ++ | ||
td (verb.s ! VPPart)) ++ | ||
tr (th "participio presente" ++ | ||
td (verb.s ! VPresPart)) ++ | ||
tr (th "passato" ++ | ||
td (verb.s ! VPast)) ++ | ||
tr (th "futuro" ++ | ||
td (verb.s ! VFut)) ++ | ||
tr (th "conditional" ++ | ||
td (verb.s ! VCond)) | ||
) ; | ||
|
||
{- --# notpresent | ||
-} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.