SimplyMaya Forums

Welcome to the forum, feel free to ask questions here.


SM Forums / Maya Questions / Programming / changing the "Quick help" window size in the maya 2012 script editor.

Programming MEL Scripts, Expressions & Programming Related Topics

Join the conversation. Reply to post
 
Thread Tools
25-11-2011, 04:42 PM   #1
Jouri
Lone Wolf Productions
 
Jouri's Avatar
 
Join Date: Nov 2011
Location: Belgium, Antwerp
Posts: 18
changing the "Quick help" window size in the maya 2012 script editor.
Since I upgraded from Maya 2009 to maya 2012 I noticed that the quickhelp frame inside the script editor window has a fixed size.
while previously when you selected quick help again the frame would double in size each time, making it easier to read everything.

Now I searched everywhere in my settings and nowhere could I find how to change it.
And since I started exploring MEL it's a feature I use alot.

So there where 2 possibilities:
A : I missed it
B : It is not there

Now i searched the internet and everywhere i see people asking that very same question I had.

So I started to dig into the Maya defined variables and created the next script that could help people running Maya 2012.

NOTE :
This script has been tested with maya 2012 only.

IMPORTANT NOTE :
Changing predifined settings can be dangerous in 99.9% of the cases if you dont know what your doing. This script is safe and i only can keep that guarantee if you use it unmodified. If for any reason the script gives you unwanted results just hit the reset button or close the quick help to restore the original maya settings.
This will also happen when you exit the quick help or maya as the script does not alter maya settings on your system but rather modifies them until the quick help is closed or maya is closed.
This means if you loose the script, Maya settings are unmodified.

Script Updated : november 27, 2011 - 07:12am CET


Code:
////////////////////////////////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////////////////////////////////
///                                                                                              ///
///               -= LoneWolf Productions =-                          __.....__                  ///
///               --------------------------                       .-'         '-.               ///
///                                                              .'               '.             ///
///                                                             /                   \            ///
///                      Script Editor                         /        |\           \           ///
///                Quick Help Window Resizer                  ;        |V \_          ;          ///
///                                                           |        |  ' \         ;          ///
///                        Autodesk                           ;        )   ,_\        |          ///
///                          Maya                             ;       /    |          ;          ///
///                          2012                              \     /      \        /           ///
///                         Script                              \    |       \      /            ///
///                                                              '.   \       \   .'             ///
///                                                                '-._|       \-'               ///
///         Created By : Caers Jouri aka Lone Wolf                     | |\     |                ///
///                     CopyRight 2011                         __lwp___/ |_'.   /______          ///
///                                                                                              ///
////////////////////////////////////////////////////////////////////////////////////////////////////
///                      2011 Lone Wolf Productions.  All rights reserved.                      ///
////////////////////////////////////////////////////////////////////////////////////////////////////

////////////////////////////////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////////////////////////////////
///                                        Important Note                                        ///
///                                        ==============                                        ///
///                    !!!This script is accessing maya defined variables!!!                     ///
///                                   Change at your own risk!                                   ///
///                                                                                              ///
///                  The script is not permanent, the settings will reset when,                  ///
///                                 Quick help or Maya is closed                                 ///
///                   this is only guaranteed if the script is used unmodified                   ///
///                                                                                              ///
////////////////////////////////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////////////////////////////////

if(`window -exists quickHelpUserResizeWindow`)
	{
		deleteUI -window quickHelpUserResizeWindow;	
	}
	
proc okQuickHelpUserResize()
	{
		global string $gCommandExecuterSideBar;
		int $newWidthQuickHelpUserResize = `intSliderGrp -q -v newQuickHelpUserResize`;
		tabLayout  -e -visible true -width $newWidthQuickHelpUserResize $gCommandExecuterSideBar;
		deleteUI -window quickHelpUserResizeWindow;		
	}
proc applyQuickHelpUserResize()
	{
		global string $gCommandExecuterSideBar;
		int $newWidthQuickHelpUserResize = `intSliderGrp -q -v newQuickHelpUserResize`;
		if ($newWidthQuickHelpUserResize < 120) 
		{
			$newWidthQuickHelpUserResize = 120;
			intSliderGrp -e -v 120 newQuickHelpUserResize;
		}		
		tabLayout  -e -visible true -width $newWidthQuickHelpUserResize $gCommandExecuterSideBar;
	}
proc resetQuickHelpUserResize()
	{
		global string $gCommandExecuterSideBar;
		intSliderGrp -e -v 120 newQuickHelpUserResize;
		tabLayout  -e -visible true -width 120 $gCommandExecuterSideBar;
	}
	
string $quickHelpUserResizeWindow = `window -title "Script Editor Quick Help Resizer" -wh 500 100  quickHelpUserResizeWindow`;

columnLayout -w 300;
intSliderGrp -label "Quick Help Frame Size" -field true
						-cal 1 "center"
						-v 120
						-cc applyQuickHelpUserResize
						-dc applyQuickHelpUserResize
						-minValue 120 -maxValue 500
						-fieldMinValue 0 -fieldMaxValue 500
						newQuickHelpUserResize;

separator;


rowColumnLayout -nc 2 -cw 1 200 -cw 2 200;
button -label "Ok" -c okQuickHelpUserResize;
button -label "Reset" -c resetQuickHelpUserResize;



int $quickHelpResizerDisclaimerConfirmationPass;
string $quickHelpResizerDisclaimerConfirmation;
string $quickHelpResizerDisclaimer = "Disclaimer."+"\n"+
									 "\n"+
									 "You agree that you use these script on your own responsibility."+"\n"+
									 "\n"+
									 " You are aware that the script may not work below Maya 2012."+"\n"+
									 "\n"+
									 "These scripts will never make modifications to your system settings, as long as they are used unaltered. Any change you make, you make on your own responsibility."+"\n"+
									 "\n"+
									 "Feedback and bug reports can reported on the forum where you have found this script, or at the following email address."+"\n"+
									 "\n"+
									 "feedback.lone.wolf.productions@dommel.be"+"\n"+
									 "\n"+
									 "\n"+
									 "By pressing the OK button, you agree to the disclaimer above."+"\n"+
									 "\n"+
									 "Lone Wolf Productions."+"\n";

$quickHelpResizerDisclaimerConfirmation = `confirmDialog -title "Quick Help Resizer- Disclaimer."
								                         -message $quickHelpResizerDisclaimer
								                         -button "Ok"
								                         -button "Cancel"
								                         -defaultButton "Ok"
								                         -cancelButton "Cancel"
								                         -dismissString "Cancel"
								                         -icon "information"`;
if($quickHelpResizerDisclaimerConfirmation == "Ok")
	{
		showWindow $quickHelpUserResizeWindow;
		window -e -wh 405 52 quickHelpUserResizeWindow;
	}
__________________
There are no stupid questions, only stupid answers.
All grammar errors are Copyrighted to me

Last edited by jouri; 27-11-2011 at 06:18 AM.
  Reply with quote
25-11-2011, 06:02 PM   #2
David
SM Site Programmer
 
David's Avatar
 
Join Date: Apr 2002
Posts: 3,125
Big thanks using 2011 at the moment I'll test this out when i go back to work.

Cheers
Dave
__________________
Worst Response To A Crisis:
From a readers' Q and A column in TV GUIDE: "If we get involved in a nuclear war, would the electromagnetic pulses from exploding bombs damage my videotapes?"
  Reply with quote
25-11-2011, 06:21 PM   #3
Jouri
Lone Wolf Productions
 
Jouri's Avatar
 
Join Date: Nov 2011
Location: Belgium, Antwerp
Posts: 18
Quote:
Big thanks using 2011 at the moment I'll test this out when i go back to work.

Cheers
Dave
I cant tell if 2011 or lower has the same issue if it does and this code does not work for you let me know so I can change it to work for 2011.
Although then i'll need the maya scripts from 2011 to see where they made changes.
located in (example) "C:\Program Files\Autodesk\MayaVersion\scripts\startup"
__________________
There are no stupid questions, only stupid answers.
All grammar errors are Copyrighted to me
  Reply with quote
27-11-2011, 06:15 AM   #4
Jouri
Lone Wolf Productions
 
Jouri's Avatar
 
Join Date: Nov 2011
Location: Belgium, Antwerp
Posts: 18
Script Updated : november 27, 2011 - 07:12am CET


note : this is not a bump, this is to notify thread subscribers
__________________
There are no stupid questions, only stupid answers.
All grammar errors are Copyrighted to me
  Reply with quote
Reply

Thread Tools


Similar Threads
Thread Thread Starter Forum Replies Last Post
Best window for Maya babyproneedlove Maya Technical Issues 2 27-08-2014 12:14 PM
trouble opening maya scene jooleyinboots Maya Technical Issues 2 03-02-2014 09:11 PM
Maya's starting window size...? Elemenopee Maya Basics & Newbie Lounge 7 25-01-2004 12:04 AM
fur rendering failed????? olivermagno Maya Materials & Textures 2 21-05-2003 01:36 AM
Docked "Properties" window in Maya 4.5 DukerX Maya Basics & Newbie Lounge 3 16-12-2002 11:23 PM