Created
November 2, 2015 15:14
-
-
Save zeffii/a01cbb28aed399146a86 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import bpy | |
for window in bpy.context.window_manager.windows: | |
for area in window.screen.areas: | |
# areas, Editors(UV/3D/Node)/Properties/Outliner...etc | |
if not area.type == 'VIEW_3D': | |
continue | |
# each area has potentially panels, and headers open. | |
# you are just interested in the 3d part. | |
for s in area.spaces: | |
if s.type == 'VIEW_3D': | |
print(area.height, area.width) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment