Skip to content

Commit 66d55ad

Browse files
Updating version.
1 parent 84881d7 commit 66d55ad

2 files changed

Lines changed: 8 additions & 8 deletions

File tree

Lib/pagebotcocoa/contexts/drawbot/drawbotstring.py

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -429,22 +429,22 @@ def findMarkers(self, reCompiled=None):
429429
def textOverflow(self, w, h, align=LEFT):
430430
"""Answers the overflowing of from the box (0, 0, w, h) as a new
431431
DrawBotString in the current context."""
432-
b = self.context.b
433432
wpt, hpt = upt(w, h)
433+
box = (0, 0, wpt, hpt)
434434

435-
# Sets the hyphenation flag from style, as in DrawBot this is set by a
435+
# Sets the hyphenation flag from style. In DrawBot this is set by a
436436
# global function, not as FormattedString attribute.
437-
# TODO: Attributes don't seem to maintain in the string or overfill copy.
437+
438+
# TODO: Attributes don't seem to stay the same in the string or overfill copy.
438439
language = self.language or 'en'
439440
hyphenation = self.hyphenation or True
440-
b.language(language)
441-
b.hyphenation(hyphenation)
442-
overflow = self.__class__(b.textOverflow(self.s, (0, 0, wpt, hpt), align), self.context)
441+
self.context.b.language(language)
442+
self.context.b.hyphenation(hyphenation)
443+
overflow = self.__class__(self.context.b.textOverflow(self.s, box, align), self.context)
443444

444445
# Pass on these parameters to the new constructed DrawBotString.
445446
overflow.language = language
446447
overflow.hyphenation = hyphenation
447-
#print('OVERFLOW', overflow.language, overflow.hyphenation, overflow[:30])
448448
return overflow
449449

450450
def getBaselines(self, w, h=None):

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
url="https://github.com/PageBot/PageBotCocoa",
2828
author = 'Petr van Blokland, Michiel Kauw-A-Tjoe',
2929
author_email = 'r@petr.com',
30-
version='0.1.1',
30+
version='0.1.2',
3131
package_dir={'': 'Lib'},
3232
packages=find_packages('Lib'),
3333
include_package_data=True,

0 commit comments

Comments
 (0)