Feature request #7573

Rewrite ParameterSelection class to return parameter value instead of its index

Added by Alexander Bruy over 11 years ago. Updated almost 8 years ago.

Status:Closed
Priority:Normal
Assignee:Victor Olaya
Category:Processing/Core
Pull Request or Patch supplied:No Resolution:fixed/implemented
Easy fix?:No Copied to github as #:16513

Description

This is rather proposal than new feature or bug.

Currently ParameterSelection accepted list of possible values and returns an index of the selected value. Maybe it makes sense to rewrite it and return value. Such approach has some advantages: using Python dict type it is very easy to show descriptive names to user and in same time pass to algorithms correct values with necessary type (string, int, double...)

If this will be accepted, issues described in #5689 will gone

History

#1 Updated by Alexander Bruy over 10 years ago

  • Category set to 63

#2 Updated by Giovanni Manghi about 10 years ago

  • Category deleted (63)
  • Project changed from 78 to QGIS Application

#3 Updated by Giovanni Manghi about 10 years ago

  • Category set to Processing/Core

#4 Updated by Giovanni Manghi about 10 years ago

  • Assignee set to Victor Olaya

#5 Updated by Alexander Bruy almost 8 years ago

  • Resolution set to fixed/implemented
  • Status changed from Open to Closed

Fixed in master. Options can be defined as (value, text)

Also available in: Atom PDF