View Issue Details Jump to Notes ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0013092ParaViewFeaturepublic2012-04-13 10:222016-08-12 09:59
ReporterIan Curington 
Assigned ToUtkarsh Ayachit 
PriorityhighSeverityminorReproducibilityhave not tried
StatusclosedResolutionmoved 
PlatformOSOS Version
Product Version3.14.1 
Target Versiongit-masterFixed in Version 
Summary0013092: Environment Variables in Statefile Data paths, Missing data visual indicator, scroll long lists
DescriptionPROBLEM:
  Saved state files are written with full data paths, requiring adjustment if moved. No visible indication if reloaded data paths are valid. If 10+ data files in state file, list becomes too long for screen size, no scrolling facility.

SOLUTION:
  Add environment variable support in data path names, making state files portable. Add visual RED/GREEN indicated for valid data paths, add Qt scrollbar.

PATCH:
   patched files: pqFixStateFilenamesDialog.[h,cxx], vtkSMStateLoader.cxx
   action: copy pqFixStateFilenamesDialog to ParaView-3.14.0\Qt\Components
           copy vtkSMStateLoader to ParaView-3.14.0\ParaViewCore\ServerManager

    DESCRIPTION: State files with filenames often require to be updated with locations of used files on new machine. Our
    patch makes this process easier and faster by allowing pathnames to contain environment variables and by adding
    indicators to "Fix Paths in State File" dialog about missing filename or directory. Also, scrolling area is added
    to the dialog to handle cases if there is large number of input files specified in state file. In case of environment
    variables, supported syntax is %VAR_NAME%, ${VAR_NAME} and $VAR_NAME. In the latest case ($VAR_NAME), VAR_NAME must be
    from [a-zA-Z0-9_-]+ language. Beside each filename box in "Fis Paths in State File" dialog is added indicator which
    when its green, currently specified file / directory is found on current machine. If it is yellow, it should be checked
    because algorithm was unable to check if it is semantically correct, and if it is red, user shoud double-check and
    possibly replace content of appropriate text-box. Also, if environment variables are present, they are replaced with
    its content (value).

    CHANGES: To make this patch, following changes were made (ParaView source patch):

       - QMap<pqFileChooserWidget*, QLabel*> IndicatorsMappings parameters is added to pqFixStateFilenamesDialog
           class declaration in pqFixStateFilenamesDialog.h,
       - QMap, pqFileChooserWidget and QLabel classes are included at the beginning of pqFixStateFilenamesDialog.h,
       - At the beginning of the file pqFixStateFilenamesDialog.cxx, new function is added SetIndicator() which
         initializes indicator's color for passed content of text-box,
       - At the beginning of the file pqFixStateFilenamesDialog.cxx, new function is added ResolveEnvironmentVariables()
         which replaces environment variables from input strings with environment variable's contents,
       - In pqFixStateFilenamesDialog class constructor, ResolveEnvironmentVariables() is called to resolve environment
         variables in every path,
       - In pqFixStateFilenamesDialog class constructor, QScrollArea is added and populated by group-boxes,
       - In pqFixStateFilenamesDialog class constructor, IndicatorsMappings table is populated and indicators are
         initialized and
       - In pqFixStateFilenamesDialog::onFileNamesChanged() is added logic for setting indicator green if file exists
         or red if file doesn't exist.
       - Added ResolveEnvironmentVariables() and TraverseTree() routines at the beginning of vtkSMStateLoader.cxx. Also
         added calling of TraverseTree() in vtkSMStateLoader::LoadStateInternal() routine.



TagsNo tags attached.
ProjectParaViewPro
Topic Name
Typeusability
Attached Filescxx file icon vtkSMStateLoader.cxx [^] (23,658 bytes) 2012-04-13 10:22
cxx file icon pqFixStateFilenamesDialog.cxx [^] (21,742 bytes) 2012-04-13 10:23
? file icon pqFixStateFilenamesDialog.h [^] (3,086 bytes) 2012-04-13 10:24
cxx file icon pqFixStateFilenamesDialog-UPDATE-20july2012.cxx [^] (22,703 bytes) 2012-07-20 09:05
png file icon 20-07-2012 13-43-56.png [^] (51,753 bytes) 2012-07-20 09:08

 Relationships

  Notes
(0028885)
Ian Curington (reporter)
2012-07-20 09:04

Please remove pqFixStateFilenamesDialog.cxx (21,742 bytes) 2012-04-13 10:23,
replace with new file pqFixStateFilenamesDialog-UPDATE-20july2012.cxx
(0028886)
Ian Curington (reporter)
2012-07-20 09:09

Screenshot added showing visual representation changes provided by this patch.
(0028963)
Ian Curington (reporter)
2012-07-29 07:09

On Tue, Jul 24, 2012 at 8:30 AM, Utkarsh commented:
"...couple of issues with the patch:
1. SetIndicator(..) won't work in client-server mode. We need to be
smart about this in client-server mode and consolidates the tests to
avoid performance degradation for a large number of files.
2. Duplication of ResolveEnvironmentVariables()
3. Style issues: indentation, missing {} after if (), etc."
(0028964)
Ian Curington (reporter)
2012-07-29 07:09

OK thank you, we will take a look at these issues.
(0038190)
Kitware Robot (administrator)
2016-08-12 09:59

Resolving issue as `moved`.

This issue tracker is no longer used. Further discussion of this issue may take place in the current ParaView Issues page linked in the banner at the top of this page.

 Issue History
Date Modified Username Field Change
2012-04-13 10:22 Ian Curington New Issue
2012-04-13 10:22 Ian Curington File Added: vtkSMStateLoader.cxx
2012-04-13 10:23 Ian Curington File Added: pqFixStateFilenamesDialog.cxx
2012-04-13 10:24 Ian Curington File Added: pqFixStateFilenamesDialog.h
2012-04-23 10:38 Utkarsh Ayachit Category (No Category) => Feature
2012-04-23 10:41 Utkarsh Ayachit Project TBD => ParaViewPro
2012-07-20 09:04 Ian Curington Note Added: 0028885
2012-07-20 09:05 Ian Curington File Added: pqFixStateFilenamesDialog-UPDATE-20july2012.cxx
2012-07-20 09:08 Ian Curington File Added: 20-07-2012 13-43-56.png
2012-07-20 09:09 Ian Curington Note Added: 0028886
2012-07-21 10:10 Utkarsh Ayachit Assigned To => Utkarsh Ayachit
2012-07-21 10:10 Utkarsh Ayachit Target Version => 4.0
2012-07-29 07:09 Ian Curington Note Added: 0028963
2012-07-29 07:09 Ian Curington Note Added: 0028964
2012-10-18 13:49 Utkarsh Ayachit Target Version 4.0 => git-master
2016-08-12 09:59 Kitware Robot Note Added: 0038190
2016-08-12 09:59 Kitware Robot Status backlog => closed
2016-08-12 09:59 Kitware Robot Resolution open => moved


Copyright © 2000 - 2018 MantisBT Team