title: How do you call gimp_file_load?
body: <pre>
  <code>
  &gt;&gt;&gt; pdb.gimp_file_load.nparams
  <strong>3</strong>
  &gt;&gt;&gt; pprint.pprint(pdb.gimp_file_load.params)
  ((0,
    'run-mode',
    'The run mode { RUN-INTERACTIVE (0), RUN-NONINTERACTIVE (1) }'),
   (4, 'filename', 'The name of the file to load'),
   (4, 'raw-filename', 'The name as entered by the user'))
  &gt;&gt;&gt; fname = '<em>a filename</em>'
  &gt;&gt;&gt; img = pdb.gimp_file_load(gimpfu.RUN_NONINTERACTIVE, fname, fname)
  Traceback (most recent call last):
  &nbsp; File "&lt;input&gt;", line 1, in &lt;module&gt;
  <strong>TypeError: wrong number of parameters</strong>
  </code>
  </pre>
  
  <p>So, what am I doing wrong here? According to the method itself, it takes three rather-well documented arguments. I pass it the three things it wants, and I receive a <code>TypeError</code>. So:</p>
  
  <ol>
  <li>What am I doing wrong?</li>
  <li>Is there a reference manual for this?</li>
  <li><p>In the tuples for the arguments, there's a 0, a 4, and a 4. What are these magic constants? According to <a href="http://www.gimp.org/docs/python/" rel="nofollow">the docs</a>, these appear to be:</p>
  
  <blockquote>
    <p>a parameter type (one of the PARAM_* constants)</p>
  </blockquote>
  
  <p>But nowhere in those docs do I find <code>PARAM_</code> constants, and I've not found them introspecting any of pdb, gimp or gimpfu.</p></li>
  </ol>
  
  <p>Just to be complete: the obvious, <code>help(pdb.gimp_file_load)</code>, isn't really that helpful:</p>
  
  <pre><code>&gt;&gt;&gt; help(pdb.gimp_file_load)
  Help on PDBFunction object:
  
  class PDBFunction(__builtin__.object)
   |  Methods defined here:
   |  
   |  __call__(...)
   |      x.__call__(...) &lt;==&gt; x(...)
   |  
   |  __repr__(...)
   |      x.__repr__() &lt;==&gt; repr(x)
   |  
   |  ----------------------------------------------------------------------
   |  Data descriptors defined here:
   |  
   |  nparams
   |  
   |  nreturn_vals
   |  
   |  params
   |  
   |  proc_author
   |  
   |  proc_blurb
   |  
   |  proc_copyright
   |  
   |  proc_date
   |  
   |  proc_help
   |  
   |  proc_name
   |  
   |  proc_type
   |  
   |  return_vals
   |  
   |  ----------------------------------------------------------------------
   |  Data and other attributes defined here:
   |  
   |  __new__ = &lt;built-in method __new__ of type object&gt;
   |      T.__new__(S, ...) -&gt; a new object with type S, a subtype of T
  </code></pre>