typos (and one file's SVN properties)

svn: r18651
This commit is contained in:
Paul Franklin 2011-12-24 19:08:19 +00:00
parent e0fa12b729
commit 4cdc101c26
8 changed files with 42 additions and 41 deletions

View File

@ -203,7 +203,7 @@ class CalcItems(object):
return self.__calc_l.calc_lines(indi_handle, fams_handle, return self.__calc_l.calc_lines(indi_handle, fams_handle,
working_lines) working_lines)
def calc_marrage(self, indi_handle, fams_handle): def calc_marriage(self, indi_handle, fams_handle):
if indi_handle == fams_handle == None: if indi_handle == fams_handle == None:
return self.__blank_marriage return self.__blank_marriage
else: else:
@ -244,13 +244,13 @@ class MakeAncestorTree(object):
myself = FamilyBox(index) myself = FamilyBox(index)
#calculate the text. #calculate the text.
myself.text = self.calc_items.calc_marrage(indi_handle, fams_handle) myself.text = self.calc_items.calc_marriage(indi_handle, fams_handle)
self.canvas.add_box(myself) self.canvas.add_box(myself)
def iterate(self, person_handle, index): def iterate(self, person_handle, index):
""" Fills out the Ancestor tree as desired/needed. """ Fills out the Ancestor tree as desired/needed.
this is an iterative apporach. this is an iterative approach.
""" """
if self.max_generations < 1: if self.max_generations < 1:
return return
@ -351,7 +351,7 @@ class MakeAncestorTree(object):
#Set __fams[cur_gen] and __pers[cur_gen] #Set __fams[cur_gen] and __pers[cur_gen]
#make sure there is a NEW int. #make sure there is a NEW int.
__index.pop() __index.pop()
#not a refernce that will clobber dads (other peoples) info #not a reference that will clobber dads (other peoples) info
__index.append((__index[cur_gen-1] *2) +1) __index.append((__index[cur_gen-1] *2) +1)
_get_person(cur_gen) _get_person(cur_gen)
@ -388,7 +388,7 @@ class MakeAncestorTree(object):
def __fill(self, index, max_fill): def __fill(self, index, max_fill):
""" Fills out the Ancestor tree as desired/needed. """ Fills out the Ancestor tree as desired/needed.
this is an iterative apporach. this is an iterative approach.
""" """
if max_fill < 1: if max_fill < 1:
return return
@ -444,7 +444,7 @@ class MakeAncestorTree(object):
#make sure there is a NEW int. #make sure there is a NEW int.
__index.pop() __index.pop()
#not a refernce that will clobber dada info #not a reference that will clobber dads info
__index.append((__index[cur_gen-1] *2) +1) __index.append((__index[cur_gen-1] *2) +1)
#__index[cur_gen] +=1 #__index[cur_gen] +=1
@ -755,7 +755,7 @@ class AncestorTree(Report):
prnnum = self.connect.get_val("inc_pagenum") prnnum = self.connect.get_val("inc_pagenum")
##################### #####################
#Setup page infomation #Setup page information
colsperpage = self.doc.get_usable_width() colsperpage = self.doc.get_usable_width()
colsperpage += self.doc.report_opts.col_width colsperpage += self.doc.report_opts.col_width

View File

@ -337,7 +337,7 @@ class Calendar(Report):
if spouse: if spouse:
spouse_name = self.get_name(spouse) spouse_name = self.get_name(spouse)
short_name = self.get_name(person) short_name = self.get_name(person)
# TEMP: this will hanlde ordered events # TEMP: this will handle ordered events
# GRAMPS 3.0 will have a new mechanism for start/stop events # GRAMPS 3.0 will have a new mechanism for start/stop events
are_married = None are_married = None
for event_ref in fam.get_event_ref_list(): for event_ref in fam.get_event_ref_list():

View File

@ -114,7 +114,7 @@ class FamilyBox(DescendantBoxBase):
class PlaceHolderBox(BoxBase): class PlaceHolderBox(BoxBase):
""" """
I am a box that does not print. I am used to make sure information I am a box that does not print. I am used to make sure information
does not run over areas that we don't wnat information (boxes) does not run over areas that we don't want information (boxes)
""" """
def __init__(self, level): def __init__(self, level):
@ -363,7 +363,7 @@ class RecurseDown:
self.database = dbase self.database = dbase
self.canvas = canvas self.canvas = canvas
self.famalies_seen = set() self.families_seen = set()
self.cols = [] self.cols = []
self.__last_direct = [] self.__last_direct = []
@ -486,7 +486,7 @@ class RecurseDown:
if not person_handle: return if not person_handle: return
if x_level > self.max_generations: return if x_level > self.max_generations: return
if s_level > 0 and s_level == self.max_spouses: return if s_level > 0 and s_level == self.max_spouses: return
if person_handle in self.famalies_seen: return if person_handle in self.families_seen: return
myself = None myself = None
person = self.database.get_person_from_handle(person_handle) person = self.database.get_person_from_handle(person_handle)
@ -504,8 +504,8 @@ class RecurseDown:
self.bold_now = 0 self.bold_now = 0
for family_handle in family_handles: for family_handle in family_handles:
if family_handle not in self.famalies_seen: if family_handle not in self.families_seen:
self.famalies_seen.add(family_handle) self.families_seen.add(family_handle)
family = self.database.get_family_from_handle(family_handle) family = self.database.get_family_from_handle(family_handle)
@ -517,7 +517,7 @@ class RecurseDown:
spouse_handle = ReportUtils.find_spouse(person, family) spouse_handle = ReportUtils.find_spouse(person, family)
if self.max_spouses > s_level and \ if self.max_spouses > s_level and \
spouse_handle not in self.famalies_seen: spouse_handle not in self.families_seen:
def _spouse_box(who): def _spouse_box(who):
return self.add_person_box((x_level, s_level+1), return self.add_person_box((x_level, s_level+1),
spouse_handle, family_handle, who) spouse_handle, family_handle, who)
@ -541,7 +541,7 @@ class RecurseDown:
_child_recurse(myself) _child_recurse(myself)
if self.max_spouses > s_level and \ if self.max_spouses > s_level and \
spouse_handle not in self.famalies_seen: spouse_handle not in self.families_seen:
#spouse_handle = ReportUtils.find_spouse(person,family) #spouse_handle = ReportUtils.find_spouse(person,family)
self.recurse(spouse_handle, x_level, s_level+1, spouse) self.recurse(spouse_handle, x_level, s_level+1, spouse)
@ -571,7 +571,7 @@ class RecurseDown:
family_b = self.add_marriage_box( family_b = self.add_marriage_box(
(level, 1), father_h, family_h, father_b) (level, 1), father_h, family_h, father_b)
retrn.append(family_b) retrn.append(family_b)
self.famalies_seen.add(family_h) self.families_seen.add(family_h)
if mother_h: if mother_h:
mother_b = self.add_person_box( mother_b = self.add_person_box(
@ -600,16 +600,16 @@ class RecurseDown:
def has_children(self, person_handle): def has_children(self, person_handle):
""" """
Quickly check to see if this person has children Quickly check to see if this person has children
still we want to respect the FamaliesSeen list still we want to respect the FamiliesSeen list
""" """
if not person_handle or person_handle in self.famalies_seen: if not person_handle or person_handle in self.families_seen:
return False return False
person = self.database.get_person_from_handle(person_handle) person = self.database.get_person_from_handle(person_handle)
for family_handle in person.get_family_handle_list(): for family_handle in person.get_family_handle_list():
if family_handle not in self.famalies_seen: if family_handle not in self.families_seen:
family = self.database.get_family_from_handle(family_handle) family = self.database.get_family_from_handle(family_handle)
@ -620,7 +620,7 @@ class RecurseDown:
def recurse_if(self, person_handle, level): def recurse_if(self, person_handle, level):
""" """
Quickly check to see if we want to continue recursion Quickly check to see if we want to continue recursion
still we want to respect the FamaliesSeen list still we want to respect the FamiliesSeen list
""" """
person = self.database.get_person_from_handle(person_handle) person = self.database.get_person_from_handle(person_handle)
@ -635,7 +635,7 @@ class RecurseDown:
show = self.has_children(person_handle) show = self.has_children(person_handle)
#if self.max_spouses == 0 and not self.has_children(person_handle): #if self.max_spouses == 0 and not self.has_children(person_handle):
# self.famalies_seen.add(person_handle) # self.families_seen.add(person_handle)
# show = False # show = False
if show: if show:
@ -681,7 +681,7 @@ class MakePersonTree(RecurseDown):
####################### #######################
#don't do center person's parents family. #don't do center person's parents family.
if family2_h: if family2_h:
self.famalies_seen.add(family2_h) self.families_seen.add(family2_h)
####################### #######################
#Center person's Fathers OTHER wives #Center person's Fathers OTHER wives
@ -764,7 +764,7 @@ class MakeFamilyTree(RecurseDown):
####################### #######################
#don't do my fathers parents family. will be done later #don't do my fathers parents family. will be done later
if family2_h: if family2_h:
self.famalies_seen.add(family2_h) self.families_seen.add(family2_h)
####################### #######################
#my father mothers OTHER husbands #my father mothers OTHER husbands
@ -782,10 +782,10 @@ class MakeFamilyTree(RecurseDown):
####################### #######################
#don't do my parents family in recurse. will be done later #don't do my parents family in recurse. will be done later
self.famalies_seen.add(family1_h) self.families_seen.add(family1_h)
##If dad has no other children from other marriages. remove him ##If dad has no other children from other marriages. remove him
if self.max_spouses == 0 and not self.has_children(father1_h): if self.max_spouses == 0 and not self.has_children(father1_h):
self.famalies_seen.add(father1_h) self.families_seen.add(father1_h)
####################### #######################
#my fathers parents! #my fathers parents!
@ -802,7 +802,7 @@ class MakeFamilyTree(RecurseDown):
#this parent again IF s/he has children #this parent again IF s/he has children
show = self.has_children(father1_h) show = self.has_children(father1_h)
if not show: if not show:
self.famalies_seen.add(father1_h) self.families_seen.add(father1_h)
family2_l = self.add_family( 0, family2, None ) family2_l = self.add_family( 0, family2, None )
@ -865,17 +865,17 @@ class MakeFamilyTree(RecurseDown):
####################### #######################
#don't do my parents family. #don't do my parents family.
self.famalies_seen = set([family1_h] ) self.families_seen = set([family1_h] )
##If mom has no other children from other marriages. remove her ##If mom has no other children from other marriages. remove her
if self.max_spouses == 0 and not self.has_children(mother1_h): if self.max_spouses == 0 and not self.has_children(mother1_h):
self.famalies_seen.add(mother1_h) self.families_seen.add(mother1_h)
if mother1_h: if mother1_h:
myfams = mother1.get_family_handle_list() myfams = mother1.get_family_handle_list()
if len(myfams) < 2: if len(myfams) < 2:
#If mom didn't have any other families, don't even do her #If mom didn't have any other families, don't even do her
#she is already here with dad and will be added later #she is already here with dad and will be added later
self.famalies_seen.add(mother1_h) self.families_seen.add(mother1_h)
####################### #######################
#my mother other spouses (if no parents) #my mother other spouses (if no parents)
@ -1029,7 +1029,7 @@ class MakeReport(object):
return None, None return None, None
def __reverse_family_group(self): def __reverse_family_group(self):
""" go through the n-1 to 0 cols of boxes looking for famalies """ go through the n-1 to 0 cols of boxes looking for families
(parents with children) that may need to be moved. """ (parents with children) that may need to be moved. """
for x_col in range(len(self.cols)-1, -1, -1): for x_col in range(len(self.cols)-1, -1, -1):
box = self.cols[x_col][0] #The first person in this col box = self.cols[x_col][0] #The first person in this col
@ -1105,7 +1105,7 @@ class MakeReport(object):
self.__move_col_from_here_down(left_group[0], amt) self.__move_col_from_here_down(left_group[0], amt)
#6. now check to see if we are working with dad and mom. #6. now check to see if we are working with dad and mom.
#if so we need to move down mariage information #if so we need to move down marriage information
#and mom! #and mom!
left_line = left_group[0].line_to left_line = left_group[0].line_to
if not left_line: if not left_line:
@ -1335,7 +1335,7 @@ class DescendTree(Report):
lines = self.Connect.get_val('note_disp') lines = self.Connect.get_val('note_disp')
##################### #####################
#Setup page infomation #Setup page information
colsperpage = self.doc.get_usable_width() colsperpage = self.doc.get_usable_width()
colsperpage += self.doc.report_opts.col_width colsperpage += self.doc.report_opts.col_width

View File

@ -240,7 +240,7 @@ class FanChart(Report):
fontsize = pt2cm(style_sheet.get_paragraph_style('FC-Title').get_font().get_size()) fontsize = pt2cm(style_sheet.get_paragraph_style('FC-Title').get_font().get_size())
# y is vertical distance to center of circle, move center down 1 fontsize # y is vertical distance to center of circle, move center down 1 fontsize
y += fontsize y += fontsize
# min_XY is the diamter of the circle, subtract two fontsize # min_XY is the diameter of the circle, subtract two fontsize
# so we dont draw outside bottom of the paper # so we dont draw outside bottom of the paper
min_xy = min(min_xy,y-2*fontsize) min_xy = min(min_xy,y-2*fontsize)
if self.max_generations > max_circular: if self.max_generations > max_circular:

View File

@ -265,12 +265,12 @@ class GtkDocBaseElement(object):
Support document element structuring and can render itself onto Support document element structuring and can render itself onto
a Cairo surface. a Cairo surface.
There are two cathegories of methods: There are two categories of methods:
1. hierarchy building methods (add_child, get_children, set_parent, 1. hierarchy building methods (add_child, get_children, set_parent,
get_parent); get_parent);
2. rendering methods (divide, draw). 2. rendering methods (divide, draw).
The hierarchy building methods generally don't have to be overriden in The hierarchy building methods generally don't have to be overridden in
the subclass, while the rendering methods (divide, draw) must be the subclass, while the rendering methods (divide, draw) must be
implemented in the subclasses. implemented in the subclasses.
@ -311,7 +311,7 @@ class GtkDocBaseElement(object):
(element.__class__, self.__class__)) (element.__class__, self.__class__))
return False return False
# append the child and set it's parent # append the child and set its parent
self._children.append(element) self._children.append(element)
element.set_parent(self) element.set_parent(self)
return True return True
@ -836,7 +836,7 @@ class GtkDocTableCell(GtkDocBaseElement):
if cell_height <> 0: if cell_height <> 0:
cell_height += 2 * v_padding cell_height += 2 * v_padding
# a cell can't be divided, return the heigth # a cell can't be divided, return the height
return (self, new_cell), cell_height return (self, new_cell), cell_height
def draw(self, cr, layout, width, cell_height, dpi_x, dpi_y): def draw(self, cr, layout, width, cell_height, dpi_x, dpi_y):
@ -926,7 +926,9 @@ class GtkDocPicture(GtkDocBaseElement):
l_margin = 0 l_margin = 0
# load the image and get its extents # load the image and get its extents
pixbuf = ImgManip.resize_to_buffer(self._filename, [img_width, img_height], self._crop) pixbuf = ImgManip.resize_to_buffer(self._filename,
[img_width, img_height],
self._crop)
pixbuf_width = pixbuf.get_width() pixbuf_width = pixbuf.get_width()
pixbuf_height = pixbuf.get_height() pixbuf_height = pixbuf.get_height()

View File

@ -296,7 +296,7 @@ class CalendarReport(Report):
if spouse: if spouse:
spouse_name = self.get_name(spouse) spouse_name = self.get_name(spouse)
short_name = self.get_name(person) short_name = self.get_name(person)
# TEMP: this will hanlde ordered events # TEMP: this will handle ordered events
# GRAMPS 3.0 will have a new mechanism for start/stop events # GRAMPS 3.0 will have a new mechanism for start/stop events
are_married = None are_married = None
for event_ref in fam.get_event_ref_list(): for event_ref in fam.get_event_ref_list():

View File

@ -1,4 +1,3 @@
# #
# Gramps - a GTK+/GNOME based genealogy program # Gramps - a GTK+/GNOME based genealogy program
# #

View File

@ -347,7 +347,7 @@ class PlaceReport(Report):
#------------------------------------------------------------------------ #------------------------------------------------------------------------
# #
# AncestorOptions # PlaceOptions
# #
#------------------------------------------------------------------------ #------------------------------------------------------------------------
class PlaceOptions(MenuReportOptions): class PlaceOptions(MenuReportOptions):