Upgrading to GitLab 11.10.0. Expect errors and see debian-infrastructure-announce@lists.debian.org for further information.

Commit e2e59f4f authored by Andreas Tille's avatar Andreas Tille

New upstream version 0.3.1

parent c4bd42b1
# Cycle - calendar for women
# Distributed under GNU Public License
# Author: Oleg S. Gints (altgo@users.sourceforge.net)
# Home page: http://cycle.sourceforge.net
0.3.1 (15.09.2005)
- change to Python 2.4 - repleace rotor module
- restore old default color scheme
- The description of the program in English from
Marco Papa Manzillo<mpapamanz@users.sourceforge.net> is corrected
- Now the name of the user is stored in a file with data.
from Miriam Ruiz <little_miry@yahoo.es>:
- fixed colors not initialized the first time a user was created.
- Added code to use wx 2.5.3 or higher if multiple versions are installed.
- Added es, ca and gl translations, and solved some bugs in locale subsystem.
- Added note alerting that this is not a reliable contraceptive method every
time a new user is created.
- Added man page
- fixed Cycle for unicode version of wx
0.3.0 (21.12.2004)
- Add translation to the german language
from Christian Weiske <cweiske@users.sourceforge.net>
- change to wxPython = 2.5.X
0.2.1 (06.06.2004)
- Add colours settings
0.2.0 (28.04.2004)
- Add translation for czech and slovak language
from Jozef Riha <zefo@seznam.cz>
- change to Python 2.3
- Add description for english language
from Marco Papa Manzillo <mpapamanz@users.sourceforge.net>
0.0.5 (30.12.2002)
- fix PopupMenu for new wxPythonGTK-
- fix exception from LANGUAGE=lang1:lang2
0.0.4 (24.10.2002)
- add setup.py and MANIFEST.in, now make new release so:
python setup.py sdist
- add check reception of hormonal contraceptive tablets
0.0.3 (16.05.2002)
- Add icons
- Convert README* in *.html
0.0.2 (05.05.2002)
- Add line under toolbar
- Change color legend "today"
- Change BackgroundColour = LIGHT BLUE
- clean up code
- Add Note
- Add calc birthday
- encode messages to locale
- Add method "by average"
- Add cycle.spec
0.0.1 (22.04.2002)
- First release
CYCLE - calendar for women
Copyright (C) 2002-2005 Oleg S. Gints
Copyright (C) 2002-2005 "CONERO lab", http://conero.lrn.ru
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
published by the Free Software Foundation; version 2 dated June,
1991, or any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
02111-1307, USA.
# Cycle - calendar for women
# Distributed under GNU Public License
# Author: Oleg S. Gints (altgo@users.sourceforge.net)
# Home page: http://cycle.sourceforge.net
1. Install Python, wxPythonGTK-2.5.x first.
3. Unpack cycle-X.X.X.tar.gz
3. Run cycle.py
include *.py
include bitmaps/*.*
include cycle.spec
include README*
include MANIFEST.in
include INSTALL
include THANKS
include BUGS
include cycle.1
recursive-include msg *.*
recursive-include icons *.*
prune */.xvpics
prune */*/.xvpics
Metadata-Version: 1.0
Name: cycle
Version: 0.3.1
Summary: Calendar for women
Home-page: http://cycle.sourceforge.net
Author: Oleg Gints
Author-email: altgo@users.sourceforge.net
License: UNKNOWN
Description: UNKNOWN
Platform: UNKNOWN
Please, help me write README in your language!
There seems to be some bug in python (python2.3, 2.3.4-19) and because
of that catalan ('ca.po') and galego ('gl.po') are not loaded from locale.py.
I had to add a couple of lines to the definition of locale_alias in
/usr/lib/python2.3/locale.py :
--- locale.py.orig 2005-04-12 22:15:37.000000000 +0200
+++ locale.py 2005-04-12 22:21:34.000000000 +0200
@@ -487,6 +487,8 @@
'c-french': 'fr_CA.ISO8859-1',
'c': 'C',
'c_c': 'C',
+ 'ca': 'ca_ES.ISO8859-1',
+ 'ca_es': 'ca_ES.ISO8859-1',
'cextend': 'en_US.ISO8859-1',
'chinese-s': 'zh_CN.eucCN',
'chinese-t': 'zh_TW.eucTW',
@@ -554,6 +556,8 @@
'ger_de': 'de_DE.ISO8859-1',
'german': 'de_DE.ISO8859-1',
'german_germany': 'de_DE.ISO8859-1',
+ 'gl': 'gl_ES.ISO8859-1',
+ 'gl_es': 'gl_ES.ISO8859-1',
'greek': 'el_GR.ISO8859-7',
'hebrew': 'iw_IL.ISO8859-8',
'hr': 'hr_HR.ISO8859-2',
Miriam Ruiz, 15-Apr-2005
<meta http-equiv="Content-Type" content="text/html;">
CYCLE - menstrual cycle tracker for women
<body BGCOLOR=white>
<h2 align=center>
menstrual cycle tracker for women
<div align=center>
<strong>15.09.2005 Version 0.3.1</strong><br>
2002-2005 (c) Oleg Gints (altgo@users.sourceforge.net)<br>
2002-2005 (c) "CONERO lab", http://conero.lrn.ru<br>
<h3 align=center>PROGRAM FEATURES</h3>
<li> Calculation of days of menstruation, based on length of cycle or
period statistics
<li> Calculation of "safe" sex days, fertile period and days to ovulation
<li> Calculation of D.O.B. (Date Of Birth) of a child
<li> Allows you to write notes
<li> Helps you decide when to take the pill.
<h3 align=center>HOW IT WORKS</h3>
It uses the <em>calendar (or rhythm) method</em> for the definition of fertile days.
For this you need to determine the duration, of last six
cycles at least.
To determine the fertile days it uses this algorithm:
<li> First day: duration of shortest cycle minus 18
<li> Last day: duration of longest cycle minus 11
<li> Ovulation: is considered to be in the middle of fertile period (To determine the exact day isn't possible with the calendar method)
More information about the calendar method is available
at: <A HREF="http://www.mama.ru/gynecolog/STA/st18.htm">
http://www.mama.ru/gynecolog/STA/st18.htm</A> (in Russian)
Date of birth of the child is counted from
the beginning of last menstruation (in obstetrics 40 weeks is normally used).
This date is corrected with the duration of a cycle (the number of days that
the cycle differs from 28 days is added or subtracted).
It is possible to check the results at:
<A HREF="http://cir.msk.ru/sroki.shtml">http://cir.msk.ru/sroki.shtml</A> (in Russian)
<H3 align=center>HOW TO USE THE PROGRAM</H3>
Mark the beginning of menstruation.
This is done by clicking with the right button on the date and chosing
"beginning of cycle". Similarly the mark can be removed.
Using duration of the last six cycles, the program will calculate and display the:
<li> Fertile period - green cells
<li> Ovulation day (the middle of the fertile period) - brightly green cell
<li> Beginning of following menstruation - pink cells
Cycle duration is set in options or is calculated as an average of last six periods.
<p>To determine the likely date of birth of the child, it is necessary
to mark the first day of the last cycle as "Pregnancy".
Depending on your preferences, you can display only "Safe" sex days
or only fertile days.
Information about a day can be seen at the bottom, by left clicking on the day.
It is possible to add a note to any date using a right click.
Days with a note are underlined.
There is a 10 percent failure rate of the calendar contraception method
This method is suitable only for women with a regular enough cycle.
If your doctor has recommended oral contraceptive pills
this program can help you take them at the right date. Familiarize yourself
thorougly with the instructions that come with the strip of tablets.
The strip can contain 21 tablets (a tablet a day for 21 days,
then 7 days pause) or 28 tablets (in this case a table a day without
interuption, over 28 days).
In the program, only the day when you first start on a strip is noted.
Program "Cycle" is distributed under <strong>GNU General Public License</strong>,
in the hope that it will be useful, but <strong>WITHOUT ANY WARRANTY</strong> (see file COPYRIGHT).
<p align=right>
<font size=-1>
Translation - Marco Papa Manzillo (mpapamanz@users.sourceforge.net)
<meta http-equiv="Content-Type" content="text/html;">
CYCLE - Ein Kalender für Frauen
<body bgcolor="white">
<h2 align=center>
Ein Kalender für Frauen
<div align="center">
<strong>15.09.2005 Version 0.3.1</strong><br>
2002-2005 (c) Oleg Gints (altgo@users.sourceforge.net)<br>
2002-2005 (c) "CONERO lab", http://conero.lrn.ru<br>
<h3 align="center">PROGRAMMFEATURES</h3>
<li>Berechnung der Menstruationstage basierend auf der Länge des Zyklus
oder der letzten Perioden</li>
<li>Berechnung der Tage des "sicheren" Sex, erhöhter Fruchtbarkeit und Eisprungs</li>
<li>Voraussage des Tages der Empfängnis eines Kindes</li>
<li>Hilft bei der Einnahme von hormonellen Empfängnispillen</li>
<h3 align="center">WIE ES FUNKTIONIERT</h3>
Das Programm verwendet die <em>Kalendermethode</em> für die Berechnung der
fruchtbaren Tage.
Dafür ist es notwendig, die Dauer von mindestens sechs vergangenen Perioden
zu kennen.
Für die Berechnung wird folgender Algorithmus verwendet:
<li>Erster Tag: Dauer des kürzesten Zyklus minus 18</li>
<li>Letzter Tag: Dauer des längsten Zyklus minus 11</li>
<li>Eisprung: Wird in der Mitte der fruchtbaren Tage vermutet (Mit der Kalendermethode ist die exakte Berechnung nicht möglich)</li>
Mehr Informationen über die Kalendermethode sind unter
<a href="http://www.mama.ru/gynecolog/STA/st18.htm">
http://www.mama.ru/gynecolog/STA/st18.htm</a> (in russisch)
Der Tag der Empfängnis (Geburt) eines Kindes wird vom Beginn der
letzten Menstruation gezählt.
Dieses Datum wird mit der Dauer eines Zyklus korrigiert (Es wird die Anzahl
der Tage addiert/subtrahiert, die die Zyklusdauer von 28 Tagen abweicht).
Es ist möglich, das Ergebnis unter folgender Adresse zu überprüfen:
<a href="http://cir.msk.ru/sroki.shtml">http://cir.msk.ru/sroki.shtml</a> (in russisch)
<H3 align="center">PROGRAMMNUTZUNG</H3>
Es ist notwendig, den Beginn der letzten Menstruationen per Hand zu
markieren. Dies geschieht durch einen Klick mit der rechten Maustaste
auf einen Tag im Kalender und der Auswahl von "Zyklusbeginn".
Auf dieselbe Art kann die Markierung entfernt werden.
Mit Hilfe der Dauer der letzten sechs Zyklen wird das Programm
folgendes berechnen:
<li>Fruchtbare Tage - grüne Zellen</li>
<li>Eisprung (Mitte der fruchtbaren Tage) - hellgrüne Zelle</li>
<li>Beginn der nächsten Menstruation - pinke Zelle</li>
Die Zyklusdauer kann in den Einstellungen festgelegt werden oder über
den Durchschnitt der Dauer der letzten 6 Zyklen berechnet werden.</p>
<p>Um den voraussichtlichen Tag der Geburt des Kindes zu berechnen
ist es nötig, den ersten Tag des letzten Zyklus zusätzlich als
"Schwanger" zu markieren.</p>
<p>Abhängig von Ihren Absichten können sowohl Tage des "sicheren" Sex
als auch nur fruchtbare Tage angezeigt werden.
Informationen über interessante Tage können mit einem Linksklick
auf den entsprechenden Tag aufgerufen werden.</p>
<p>Es ist möglich, Notizen zu einem Tag hinzuzufügen. Tage
mit Notiz werden unterstrichen dargestellt.</p>
<p><em>Hinweis:</em> Die Fehlerrate der Kalendermethod liegt bei
ca. 10 Prozent. Sie ist nur für Frauen mit einer regelmäßigen Periode
zu empfehlen.</p>
<p>Wenn Ihnen Ihr Arzt die Pille verschrieben hat, wird Ihnen das Programm
bei der Einhaltung der regelmäßigen Einnahme helfen.
Machen Sie sich aber trotzdem mit den Hinweisen auf der
Packungsbeilage vertraut!
Eine Packung kann 21 Tabletten (Der Zyklus dauert 21 Tage, danach 7 Tage Pause)
oder 28 Tabletten enthalten - diese werden dann jeden Tag eingenommen.
Im Programm wird nur der Tag markiert, an dem die erste Tablette eingenommen
werden muss.</p>
<p>Das Programm "Cycle" wird unter der <strong>GNU General Public License</strong>
verteilt in der Hoffnung, dass es nützlich sein wird. Es gibt aber keine Garantie,
dass es korrekt oder überhaupt funktioniert. (Siehe Datei "COPYRIGHT")</p>
<p align="right">
<font size="-1">
Übersetzung: Christian Weiske (cweiske@users.sourceforge.net)
<meta http-equiv="Content-Type" content="text/html; charset=koi8-r">
<body BGCOLOR=white>
<h2 align=center>
<div align=center>
<strong>15.09.2005 0.3.1</strong><br>
2002-2005 (c) (altgo@users.sourceforge.net)<br>
2002-2005 (c) "CONERO lab", http://conero.lrn.ru<br>
<h3 align=center> :</h3>
<li> "" ,
<h3 align=center> .</h3>
<em> </em>.
11, .
18, .
<A HREF="http://www.mama.ru/gynecolog/STA/st18.htm">
http://www.mama.ru/gynecolog/STA/st18.htm </A>
( ) 40
- ,
28 .
<A HREF="http://cir.msk.ru/sroki.shtml">http://cir.msk.ru/sroki.shtml</A>
<H3 ALIGN=center> .</H3>
<P> .
" ".
( - ).
). -
, .
"" .
<P> ,
<P> ,
<P> ,
10 .
. ,
. 21 -
21 , 7 , 28 -
28 .
1- .
<H3 ALIGN=center> .</H3>
<P> Cycle
<STRONG>GNU General Public License</STRONG>,
Sergey Kalinin (aka BanZaj) banzaj@lrn.ru (pogramm tester)
Jozef Riha <zefo@seznam.cz> translation for czech and slovak language
Marco Papa Manzillo <mpapamanz@users.sourceforge.net> - translation description
for english language
Christian Weiske <cweiske@users.sourceforge.net> translation to the german language
Miriam Ruiz <little_miry@yahoo.es> for greater work on improvement and correction
of the program (see CHANGELOG)
File added
This diff is collapsed.
......@@ -25,11 +25,11 @@ The program is capable of:
\- Calculate of the days of menstruation, based on length of the cycle or on statistics of a period.
\- Calculate the "safe" sex days, fertile period and day to ovulations
\- Definition of D.O.B . (Date Of Birth) of a child
\- Allows one to write notes
\- Allows to write notes
\- Helps to supervise reception of hormonal contraceptive tablets
It uses the calendar method for the definition of fertile days. For this is necessary to determine duration, at least, of last six cycles. For determine the fertile days it uses this algorithm:
It uses the calendar method for the definition of fertile days. For this is necessary to determine duration, at least, of last six cycles. For determine the fertile days it uses this algoritm:
\- First day: duration of shortest cycle minus 18
\- Last day: duration of longest cycle minus 11
......@@ -76,8 +76,10 @@ This manual page was written for Debian by Miriam Ruiz <little_miry@yahoo.es>.
You can find cycle's home page at:
.URL http://cycle.sourceforge.net/
More information about calendar method are available at:
.URL http://www.mama.ru/gynecolog/STA/st18.htm
http://www.mama.ru/gynecolog/STA/st18.htm (in Russian)
#!/usr/bin/env python
# coding: koi8-r
# Cycle - calendar for women
# Distributed under GNU Public License
# Author: Oleg S. Gints (altgo@users.sourceforge.net)
# Home page: http://cycle.sourceforge.net
import os, sys, gettext
import locale
import wxversion
import wx
import wx.html
import wx.lib.colourdb
from cal_year import *
from save_load import *
from dialogs import *
from set_dir import *
#from prn import *
import gettext
import __builtin__
if not '__WXMSW__' in wx.PlatformInfo:
for lang_env_var in ('LANGUAGE', 'LC_ALL', 'LC_CTYPE', 'LANG'):
if lang_find:
if os.environ.has_key(lang_env_var):
for s_lang in env_language.split(':'): # if set more languages
lang=[ dl[0][0:2] ]
l=gettext.translation('cycle', msg_dir, lang)
__builtin__.__dict__['_'] = lambda s: l.ugettext(s)
__builtin__.__dict__['_'] = lambda s: l.ugettext(s).encode(dl[1])
_('try decode this string')
break #language was found
else: #for MS Windows
lang=[ dl[0][0:2] ]
l=gettext.translation('cycle', msg_dir, lang)
__builtin__.__dict__['_'] = lambda s: l.ugettext(s)
__builtin__.__dict__['_'] = lambda s: l.ugettext(s).encode(dl[1])
_('try decode this string')
if not lang_find:
__builtin__.__dict__['_'] = lambda s: s
class MyFrame(wx.Frame):
def __init__(self, parent, ID, title):
wx.Frame.__init__(self, parent, ID, title,
wx.DefaultPosition, wx.Size(800, 600))
# self.printer = wx.HtmlEasyPrinting()
icon = wx.Icon(os.path.join(icons_dir,'mini/cycle.xpm'), wx.BITMAP_TYPE_XPM)
self.MakeToolMenu() # toolbar
wx.EVT_CLOSE(self, self.OnCloseWindow)
def OnCloseWindow(self, event):
Save_Cycle(cycle.name, cycle.passwd, cycle.file)
def TimeToQuit(self, event):
def MakeToolMenu(self):
tb = self.CreateToolBar(wx.TB_HORIZONTAL|wx.NO_BORDER)
tb.SetToolBitmapSize( wx.Size(24,24) )
SetToolPath(self, tb, 10, os.path.join(bitmaps_dir,'dec.png'), _('Dec Year'))
wx.EVT_TOOL(self, 10, self.OnDecYear)
SetToolPath(self, tb, 20, os.path.join(bitmaps_dir,'curr.png'), _('Current Year'))
wx.EVT_TOOL(self, 20, self.OnCurrent)
SetToolPath(self, tb, 30, os.path.join(bitmaps_dir,'inc.png'), _('Inc Year'))
wx.EVT_TOOL(self, 30, self.OnIncYear)
SetToolPath(self, tb, 40, os.path.join(bitmaps_dir,'legend.png'), _('Legend'))
wx.EVT_TOOL(self, 40, self.Legend)
SetToolPath(self, tb, 50, os.path.join(bitmaps_dir,'set.png'), _('Settings'))
wx.EVT_TOOL(self, 50, self.Settings)
SetToolPath(self, tb, 55, os.path.join(bitmaps_dir,'help.png'), _('Help'))
wx.EVT_TOOL(self, 55, self.Info)
# SetToolPath(self, tb, 57, os.path.join(bitmaps_dir,'help.png'), _('Print'))
# wx.EVT_TOOL(self, 57, self.test)
SetToolPath(self, tb, 60, os.path.join(bitmaps_dir,'exit.png'), _('Exit'))
wx.EVT_TOOL(self, 60, self.TimeToQuit)
def test(self, event):
#rpt = report_year(self.cal.year)
dlg = Colour_Dlg(self)
def Legend(self,event):
dlg = Legend_Dlg(self)
def Settings(self,event):
dlg = Settings_Dlg(self)
if dlg.ShowModal() == wx.ID_OK:
def Info(self, event):
global lang
if not os.path.isfile(f_name):
f = open(f_name, "r")
msg = f.read()
dlg = Help_Dlg(self, _('Help'), msg)
# increment and decrement toolbar controls
def OnIncYear(self, event):
def OnDecYear(self, event):
def OnCurrent(self, event):
def SetToolPath(self, tb, id, bmp, title):
global dir_path
tb.AddSimpleTool(id, wx.Bitmap(os.path.join(dir_path, bmp), wx.BITMAP_TYPE_PNG),
title, title)
class MyApp(wx.App):
def OnInit(self):
if ret=='bad_login':
return True
elif ret=='not_first':
dlg = Login_Dlg(None)
if dlg.ShowModal() == wx.ID_CANCEL:
return True
return True
def frame_init(self):
frame = MyFrame(None, -1,"")