summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTerry Jan Reedy <tjreedy@udel.edu>2015-09-25 04:49:44 (GMT)
committerTerry Jan Reedy <tjreedy@udel.edu>2015-09-25 04:49:44 (GMT)
commitb5bb6f3a59044aaa137a10da0a4fa9ae6a62020f (patch)
tree3bf7b2376c7251871fe1db6798c4c520766b34fd
parent6e5bf064a1c9604ecd72d2ce3a8d37dc65885cc9 (diff)
parent3acda6e854742fedbe2211685691f5982cdf6700 (diff)
downloadcpython-b5bb6f3a59044aaa137a10da0a4fa9ae6a62020f.zip
cpython-b5bb6f3a59044aaa137a10da0a4fa9ae6a62020f.tar.gz
cpython-b5bb6f3a59044aaa137a10da0a4fa9ae6a62020f.tar.bz2
Merge with 3.5
-rw-r--r--Lib/idlelib/help.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/Lib/idlelib/help.py b/Lib/idlelib/help.py
index 141564e..953dd8d 100644
--- a/Lib/idlelib/help.py
+++ b/Lib/idlelib/help.py
@@ -28,6 +28,7 @@ from html.parser import HTMLParser
from os.path import abspath, dirname, isdir, isfile, join
from tkinter import Tk, Toplevel, Frame, Text, Scrollbar, Menu, Menubutton
from tkinter import font as tkfont
+from idlelib.configHandler import idleConf
use_ttk = False # until available to import
if use_ttk:
@@ -158,8 +159,11 @@ class HelpText(Text):
"Display help.html."
def __init__(self, parent, filename):
"Configure tags and feed file to parser."
+ uwide = idleConf.GetOption('main', 'EditorWindow', 'width', type='int')
+ uhigh = idleConf.GetOption('main', 'EditorWindow', 'height', type='int')
+ uhigh = 3 * uhigh // 4 # lines average 4/3 of editor line height
Text.__init__(self, parent, wrap='word', highlightthickness=0,
- padx=5, borderwidth=0)
+ padx=5, borderwidth=0, width=uwide, height=uhigh)
normalfont = self.findfont(['TkDefaultFont', 'arial', 'helvetica'])
fixedfont = self.findfont(['TkFixedFont', 'monaco', 'courier'])