Hi, I have a utility which runs from a formal module (which effectively acts as the template) allowing the user to:
-
select one of the defined views, and
-
copy the selected view to either a single formal module or all formal modules within a folder.
Following the copy to the formal module(s), I wish to resize the window of the formal module to match the size of the source module window.
I easily found routines which get and set the sizes and positions of DB windows and think I found the method of GETTING the size of a Module window, using:
-
int ModuleSizeX = width window SourceModule, and
-
int ModuleSizeY = height window SourceModule
...but having trouble SETTING the width and height of the TargetModule. Can anyone help?
Thanks in advance,
Chris
SystemAdmin - Tue Mar 03 04:26:19 EST 2009 |
|
Re: Copy Views - is there a way of resizing a Module Window (not a DBE Window)? SystemAdmin - Tue Mar 03 07:03:09 EST 2009
Don't know if it is possible to change module window size interactively. But if you are copying views, then look at the DXL example lib\dxl\util\copyview.inc, which uses the undocumented function copyWindowSettings to copy e.g. the window size from one view to another.
|
|
Re: Copy Views - is there a way of resizing a Module Window (not a DBE Window)? SystemAdmin - Tue Mar 03 07:24:44 EST 2009 SystemAdmin - Tue Mar 03 07:03:09 EST 2009
Don't know if it is possible to change module window size interactively. But if you are copying views, then look at the DXL example lib\dxl\util\copyview.inc, which uses the undocumented function copyWindowSettings to copy e.g. the window size from one view to another.
Well...except it does not copy the window size and position settings. At least did not on DOORS 8.3. So no solution from this example script.
|
|
Re: Copy Views - is there a way of resizing a Module Window (not a DBE Window)? mcnairk - Tue Mar 03 08:49:31 EST 2009 SystemAdmin - Tue Mar 03 07:24:44 EST 2009
Well...except it does not copy the window size and position settings. At least did not on DOORS 8.3. So no solution from this example script.
Sorry, I don't have the answer, but I have a related question - is there a way to copy the Column property "Text Color By attribute" using Copyview?
Thanks,
Ken.
|
|
Re: Copy Views - is there a way of resizing a Module Window (not a DBE Window)? SystemAdmin - Wed Mar 04 05:26:29 EST 2009 mcnairk - Tue Mar 03 08:49:31 EST 2009
Sorry, I don't have the answer, but I have a related question - is there a way to copy the Column property "Text Color By attribute" using Copyview?
Thanks,
Ken.
That seems to be copied according to my testing.
|
|
Re: Copy Views - is there a way of resizing a Module Window (not a DBE Window)? mcnairk - Wed Mar 04 08:03:18 EST 2009 SystemAdmin - Wed Mar 04 05:26:29 EST 2009
That seems to be copied according to my testing.
What version of Copy View and DOORS are you using?
I'm using V2.2 06-May-19 in DOORS 8.2.
Thanks,
Ken.
|
|
Re: Copy Views - is there a way of resizing a Module Window (not a DBE Window)? SystemAdmin - Wed Mar 04 08:53:24 EST 2009 mcnairk - Wed Mar 04 08:03:18 EST 2009
What version of Copy View and DOORS are you using?
I'm using V2.2 06-May-19 in DOORS 8.2.
Thanks,
Ken.
Maybe we are talking of different copyview file? I am running DOORS 8.3 and in that dxl/utils/copyview.inc supplied along with DOORS there is no version information than
// %full_filespec: copyview.inc~14:dxl:ERS#1 %
..what ever that is.
|
|
Re: Copy Views - is there a way of resizing a Module Window (not a DBE Window)? SystemAdmin - Fri Mar 06 05:07:19 EST 2009
Hi dudes,
Please find attached a copy of the kitchen utility 'Copy Views' I was handed yesterday. It appears to do what I was hoping it would, i.e. resizing the target module based on the dimensions of the source module.
I had a quick look at the code but I can't find the version number just in case anyone asked.
Just out of a matter of interest, the utility I wrote opens the module in EDIT mode and makes it visible to the user, the kitchen utility, however, opens the module in READ mode (and switches between hidden and visible at various times). Would this single fact be the reason why my utility doesn't copy across the dimenensions of the window??
Chris.
Attachments
attachment_14225586_KitchenUtilityViews.zip
|
|
Re: Copy Views - is there a way of resizing a Module Window (not a DBE Window)? llandale - Sat Mar 07 14:06:07 EST 2009 SystemAdmin - Fri Mar 06 05:07:19 EST 2009
Hi dudes,
Please find attached a copy of the kitchen utility 'Copy Views' I was handed yesterday. It appears to do what I was hoping it would, i.e. resizing the target module based on the dimensions of the source module.
I had a quick look at the code but I can't find the version number just in case anyone asked.
Just out of a matter of interest, the utility I wrote opens the module in EDIT mode and makes it visible to the user, the kitchen utility, however, opens the module in READ mode (and switches between hidden and visible at various times). Would this single fact be the reason why my utility doesn't copy across the dimenensions of the window??
Chris.
Didn't study the scripts, but you don't need to open the module Edit to modify the Views; which makes sense since modifying views doesn't change any of the underlying data.
Scripts should routinely open modules read unless they intend to perform changes.
|
|
Re: Copy Views - is there a way of resizing a Module Window (not a DBE Window)? ePiallat - Mon Mar 09 06:13:16 EDT 2009 llandale - Sat Mar 07 14:06:07 EST 2009
Didn't study the scripts, but you don't need to open the module Edit to modify the Views; which makes sense since modifying views doesn't change any of the underlying data.
Scripts should routinely open modules read unless they intend to perform changes.
From DOORS 8 however you need edit mode to change anything about the "default view". (which was not the case in 2002 when the script was released, and anyway the script doen't attempt to copy module nor current user default View settings, see below)
By the way, I can't see where in the script resizes the window.
In fact, it reads:
/*
Known issues:
Does not copy Sort Criteria
Does not copy Window Size and Position settings
Does not copy View Access Rights settings
Does not copy Module and current user default View settings
*/
I remember using the void draw(Module,int,int,int,int,int,int,int,int) function for this, but I can't remember neither syntax nor order of arguments.
And wild guess about this throws ugly errors.
– Éric
|
|