paloYaKgwedi
→ month()Returns the month from the computer's clock, from 1 to 12.
paloYaKgwedi()January is 1 and December is 12. Note that underneath, months are counted from 0; Bopa corrects that, so the number you see is the one you expect.
A kgwedi is not a ngwedi. It is often said that one Setswana word covers both the calendar month and the moon in the sky. No source consulted says so:
kgwediis written as month only, while the word for the moon isngwedi.
Examples
Section titled “Examples”tiro setaLoeto() {
thalaKanefase(400, 200);
bokamorago(240);
tlogelaMothalo();
metlha k = paloYaKgwedi();
gopheta (diri i = 1; i <= 12; i = i + 1) {
fa (i === k) {
tlatsaMmala(220, 90, 70);
} gongwe {
tlatsaMmala(205, 210, 218);
}
thalaKhutlonne(14 + (i - 1) * 31, 70, 26, 60);
}
tlatsaMmala(40);
bogoloJwaMokwalo(16);
thalaMokwalo('kgwedi ' + k, 14, 40);
tlhalosa('Mabokoso a le lesome le bobedi a a emetseng dikgwedi, mme la kgwedi ya gompieno le khibidu.');
}