eric7/UI/UserInterface.py

branch
eric7
changeset 8729
226da2e26a84
parent 8728
62b44a7c0a3a
child 8740
d60ae328c740
equal deleted inserted replaced
8728:62b44a7c0a3a 8729:226da2e26a84
167 167
168 ErrorLogFileName = "eric7_error.log" 168 ErrorLogFileName = "eric7_error.log"
169 169
170 def __init__(self, app, locale, splash, plugin, disabledPlugins, 170 def __init__(self, app, locale, splash, plugin, disabledPlugins,
171 noOpenAtStartup, noCrashOpenAtStartup, disableCrashSession, 171 noOpenAtStartup, noCrashOpenAtStartup, disableCrashSession,
172 smallScreen, restartArguments, originalPathString): 172 restartArguments, originalPathString):
173 """ 173 """
174 Constructor 174 Constructor
175 175
176 @param app reference to the application object 176 @param app reference to the application object
177 @type EricApplication 177 @type EricApplication
192 file found at statup 192 file found at statup
193 @type bool 193 @type bool
194 @param disableCrashSession flag indicating to disable the crash session 194 @param disableCrashSession flag indicating to disable the crash session
195 support 195 support
196 @type bool 196 @type bool
197 @param smallScreen flag indicating to use the interface for small
198 screens (i.e. smaller than 1920 x 1080)
199 @type bool
200 @param restartArguments list of command line parameters to be used for 197 @param restartArguments list of command line parameters to be used for
201 a restart 198 a restart
202 @type list of str 199 @type list of str
203 @param originalPathString original PATH environment variable 200 @param originalPathString original PATH environment variable
204 @type str 201 @type str
217 self.__disableCrashSession = disableCrashSession 214 self.__disableCrashSession = disableCrashSession
218 self.__disabledPlugins = disabledPlugins[:] 215 self.__disabledPlugins = disabledPlugins[:]
219 216
220 self.__originalPathString = originalPathString 217 self.__originalPathString = originalPathString
221 218
222 primaryScreenSize = app.primaryScreen().size() 219 if app.usesSmallScreen():
223 if (
224 smallScreen or
225 primaryScreenSize.width() < 1920 or
226 primaryScreenSize.height() < 1080
227 ):
228 # override settings for small screens 220 # override settings for small screens
229 Preferences.setUI("LayoutType", "Sidebars") 221 Preferences.setUI("LayoutType", "Sidebars")
230 Preferences.setUI("CombinedLeftRightSidebar", True) 222 Preferences.setUI("CombinedLeftRightSidebar", True)
231 223
232 self.__layoutType = Preferences.getUI("LayoutType") 224 self.__layoutType = Preferences.getUI("LayoutType")

eric ide

mercurial