summary refs log tree commit diff stats
path: root/doc/pydoc/ranger.actions.html
diff options
context:
space:
mode:
authorhut <hut@lavabit.com>2010-02-16 01:56:21 +0100
committerhut <hut@lavabit.com>2010-02-16 02:03:46 +0100
commit34a60763e79546e0f84e30fbcc430632f3dbb39e (patch)
tree595579022daa922b3e4945928b4478c0797b3b2c /doc/pydoc/ranger.actions.html
parent0654d6d093f8e78033b9dcafcb52bbdcd92aed0c (diff)
downloadranger-34a60763e79546e0f84e30fbcc430632f3dbb39e.tar.gz
incremented version number and updated pydoc html files v1.0.3
Diffstat (limited to 'doc/pydoc/ranger.actions.html')
-rw-r--r--doc/pydoc/ranger.actions.html29
1 files changed, 15 insertions, 14 deletions
diff --git a/doc/pydoc/ranger.actions.html b/doc/pydoc/ranger.actions.html
index 8d484eb1..761d2299 100644
--- a/doc/pydoc/ranger.actions.html
+++ b/doc/pydoc/ranger.actions.html
@@ -1,6 +1,6 @@
+
 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
 <html><head><title>Python: module ranger.actions</title>
-<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
 </head><body bgcolor="#f0f0f8">
 
 <table width="100%" cellspacing=0 cellpadding=2 border=0 summary="heading">
@@ -8,7 +8,7 @@
 <td valign=bottom>&nbsp;<br>
 <font color="#ffffff" face="helvetica, arial">&nbsp;<br><big><big><strong><a href="ranger.html"><font color="#ffffff">ranger</font></a>.actions</strong></big></big></font></td
 ><td align=right valign=bottom
-><font color="#ffffff" face="helvetica, arial"><a href=".">index</a><br><a href="file:/home/hut/work/ranger/ranger/actions.py">/home/hut/work/ranger/ranger/actions.py</a></font></td></tr></table>
+><font color="#ffffff" face="helvetica, arial"><a href=".">index</a><br><a href="file:/home/hut/ranger/ranger/actions.py">/home/hut/ranger/ranger/actions.py</a></font></td></tr></table>
     <p><tt>#&nbsp;Copyright&nbsp;(c)&nbsp;2009,&nbsp;2010&nbsp;hut&nbsp;&lt;hut@lavabit.com&gt;<br>
 #<br>
 #&nbsp;Permission&nbsp;to&nbsp;use,&nbsp;copy,&nbsp;modify,&nbsp;and/or&nbsp;distribute&nbsp;this&nbsp;software&nbsp;for&nbsp;any<br>
@@ -30,10 +30,11 @@
     
 <tr><td bgcolor="#aa55cc"><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td>&nbsp;</td>
 <td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=top><a href="ranger.gui.widgets.console_mode.html">ranger.gui.widgets.console_mode</a><br>
-</td><td width="25%" valign=top><a href="ranger.fsobject.html">ranger.fsobject</a><br>
+<a href="ranger.fsobject.html">ranger.fsobject</a><br>
 </td><td width="25%" valign=top><a href="os.html">os</a><br>
+<a href="ranger.html">ranger</a><br>
 </td><td width="25%" valign=top><a href="shutil.html">shutil</a><br>
-</td></tr></table></td></tr></table><p>
+</td><td width="25%" valign=top></td></tr></table></td></tr></table><p>
 <table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
 <tr bgcolor="#ee77aa">
 <td colspan=3 valign=bottom>&nbsp;<br>
@@ -47,7 +48,7 @@
 <dt><font face="helvetica, arial"><a href="ranger.actions.html#Actions">Actions</a>(<a href="ranger.shared.html#EnvironmentAware">ranger.shared.EnvironmentAware</a>, <a href="ranger.shared.settings.html#SettingsAware">ranger.shared.settings.SettingsAware</a>)
 </font></dt></dl>
 </dd>
-<dt><font face="helvetica, arial"><a href="ranger.shared.settings.html#SettingsAware">ranger.shared.settings.SettingsAware</a>(<a href="builtins.html#object">builtins.object</a>)
+<dt><font face="helvetica, arial"><a href="ranger.shared.settings.html#SettingsAware">ranger.shared.settings.SettingsAware</a>(<a href="__builtin__.html#object">__builtin__.object</a>)
 </font></dt><dd>
 <dl>
 <dt><font face="helvetica, arial"><a href="ranger.actions.html#Actions">Actions</a>(<a href="ranger.shared.html#EnvironmentAware">ranger.shared.EnvironmentAware</a>, <a href="ranger.shared.settings.html#SettingsAware">ranger.shared.settings.SettingsAware</a>)
@@ -66,11 +67,11 @@
 <dd><a href="ranger.shared.html#EnvironmentAware">ranger.shared.EnvironmentAware</a></dd>
 <dd><a href="ranger.shared.html#Awareness">ranger.shared.Awareness</a></dd>
 <dd><a href="ranger.shared.settings.html#SettingsAware">ranger.shared.settings.SettingsAware</a></dd>
-<dd><a href="builtins.html#object">builtins.object</a></dd>
+<dd><a href="__builtin__.html#object">__builtin__.object</a></dd>
 </dl>
 <hr>
 Methods defined here:<br>
-<dl><dt><a name="Actions-cd"><strong>cd</strong></a> = <a href="#Actions-enter_dir">enter_dir</a>(self, path)</dt></dl>
+<dl><dt><a name="Actions-cd"><strong>cd</strong></a>(self, path, remember<font color="#909090">=True</font>)</dt><dd><tt>enter&nbsp;the&nbsp;directory&nbsp;at&nbsp;the&nbsp;given&nbsp;path,&nbsp;remember=True</tt></dd></dl>
 
 <dl><dt><a name="Actions-copy"><strong>copy</strong></a>(self)</dt><dd><tt>Copy&nbsp;the&nbsp;selected&nbsp;items</tt></dd></dl>
 
@@ -86,17 +87,17 @@ Methods defined here:<br>
 
 <dl><dt><a name="Actions-display_log"><strong>display_log</strong></a>(self)</dt></dl>
 
-<dl><dt><a name="Actions-edit_file"><strong>edit_file</strong></a>(self)</dt><dd><tt>Calls&nbsp;execute_file&nbsp;with&nbsp;the&nbsp;current&nbsp;file&nbsp;and&nbsp;app='editor'</tt></dd></dl>
+<dl><dt><a name="Actions-edit_file"><strong>edit_file</strong></a>(self, file<font color="#909090">=None</font>)</dt><dd><tt>Calls&nbsp;execute_file&nbsp;with&nbsp;the&nbsp;current&nbsp;file&nbsp;and&nbsp;app='editor'</tt></dd></dl>
 
 <dl><dt><a name="Actions-enter_bookmark"><strong>enter_bookmark</strong></a>(self, key)</dt><dd><tt>Enter&nbsp;the&nbsp;bookmark&nbsp;with&nbsp;the&nbsp;name&nbsp;&lt;key&gt;</tt></dd></dl>
 
-<dl><dt><a name="Actions-enter_dir"><strong>enter_dir</strong></a>(self, path)</dt><dd><tt>Enter&nbsp;the&nbsp;directory&nbsp;at&nbsp;the&nbsp;given&nbsp;path</tt></dd></dl>
+<dl><dt><a name="Actions-enter_dir"><strong>enter_dir</strong></a>(self, path, remember<font color="#909090">=False</font>)</dt><dd><tt>Enter&nbsp;the&nbsp;directory&nbsp;at&nbsp;the&nbsp;given&nbsp;path</tt></dd></dl>
 
 <dl><dt><a name="Actions-execute_command"><strong>execute_command</strong></a>(self, cmd, **kw)</dt></dl>
 
 <dl><dt><a name="Actions-execute_file"><strong>execute_file</strong></a>(self, files, **kw)</dt><dd><tt>Execute&nbsp;a&nbsp;file.<br>
 app&nbsp;is&nbsp;the&nbsp;name&nbsp;of&nbsp;a&nbsp;method&nbsp;in&nbsp;Applications,&nbsp;without&nbsp;the&nbsp;"app_"<br>
-flags&nbsp;is&nbsp;a&nbsp;string&nbsp;consisting&nbsp;of&nbsp;applications.ALLOWED_FLAGS<br>
+flags&nbsp;is&nbsp;a&nbsp;string&nbsp;consisting&nbsp;of&nbsp;runner.ALLOWED_FLAGS<br>
 mode&nbsp;is&nbsp;a&nbsp;positive&nbsp;integer.<br>
 Both&nbsp;flags&nbsp;and&nbsp;mode&nbsp;specify&nbsp;how&nbsp;the&nbsp;program&nbsp;is&nbsp;run.</tt></dd></dl>
 
@@ -108,7 +109,7 @@ Both&nbsp;flags&nbsp;and&nbsp;mode&nbsp;specify&nbsp;how&nbsp;the&nbsp;program&n
 
 <dl><dt><a name="Actions-history_go"><strong>history_go</strong></a>(self, relative)</dt><dd><tt>Move&nbsp;back&nbsp;and&nbsp;forth&nbsp;in&nbsp;the&nbsp;history</tt></dd></dl>
 
-<dl><dt><a name="Actions-mark"><strong>mark</strong></a>(self, all<font color="#909090">=False</font>, toggle<font color="#909090">=False</font>, val<font color="#909090">=None</font>, movedown<font color="#909090">=None</font>)</dt><dd><tt>A&nbsp;wrapper&nbsp;for&nbsp;the&nbsp;directory.mark_xyz&nbsp;functions.<br>
+<dl><dt><a name="Actions-mark"><strong>mark</strong></a>(self, all<font color="#909090">=False</font>, toggle<font color="#909090">=False</font>, val<font color="#909090">=None</font>, movedown<font color="#909090">=None</font>, narg<font color="#909090">=1</font>)</dt><dd><tt>A&nbsp;wrapper&nbsp;for&nbsp;the&nbsp;directory.mark_xyz&nbsp;functions.<br>
 &nbsp;<br>
 Arguments:<br>
 all&nbsp;-&nbsp;change&nbsp;all&nbsp;files&nbsp;of&nbsp;the&nbsp;current&nbsp;directory&nbsp;at&nbsp;once?<br>
@@ -125,13 +126,13 @@ val&nbsp;-&nbsp;mark&nbsp;or&nbsp;unmark?</tt></dd></dl>
 
 <dl><dt><a name="Actions-move_pointer_by_percentage"><strong>move_pointer_by_percentage</strong></a>(self, relative<font color="#909090">=0</font>, absolute<font color="#909090">=None</font>, narg<font color="#909090">=None</font>)</dt><dd><tt>Move&nbsp;the&nbsp;pointer&nbsp;down&nbsp;by&nbsp;&lt;relative&gt;%&nbsp;or&nbsp;to&nbsp;&lt;absolute&gt;%</tt></dd></dl>
 
-<dl><dt><a name="Actions-move_right"><strong>move_right</strong></a>(self, mode<font color="#909090">=0</font>)</dt><dd><tt>Enter&nbsp;the&nbsp;current&nbsp;directory&nbsp;or&nbsp;execute&nbsp;the&nbsp;current&nbsp;file</tt></dd></dl>
+<dl><dt><a name="Actions-move_right"><strong>move_right</strong></a>(self, mode<font color="#909090">=0</font>, narg<font color="#909090">=None</font>)</dt><dd><tt>Enter&nbsp;the&nbsp;current&nbsp;directory&nbsp;or&nbsp;execute&nbsp;the&nbsp;current&nbsp;file</tt></dd></dl>
 
 <dl><dt><a name="Actions-notify"><strong>notify</strong></a>(self, text, duration<font color="#909090">=4</font>, bad<font color="#909090">=False</font>)</dt></dl>
 
 <dl><dt><a name="Actions-open_console"><strong>open_console</strong></a>(self, mode<font color="#909090">=':'</font>, string<font color="#909090">=''</font>)</dt><dd><tt>Open&nbsp;the&nbsp;console&nbsp;if&nbsp;the&nbsp;current&nbsp;UI&nbsp;supports&nbsp;that</tt></dd></dl>
 
-<dl><dt><a name="Actions-paste"><strong>paste</strong></a>(self)</dt><dd><tt>Paste&nbsp;the&nbsp;selected&nbsp;items&nbsp;into&nbsp;the&nbsp;current&nbsp;directory</tt></dd></dl>
+<dl><dt><a name="Actions-paste"><strong>paste</strong></a>(self, overwrite<font color="#909090">=False</font>)</dt><dd><tt>Paste&nbsp;the&nbsp;selected&nbsp;items&nbsp;into&nbsp;the&nbsp;current&nbsp;directory</tt></dd></dl>
 
 <dl><dt><a name="Actions-paste_symlink"><strong>paste_symlink</strong></a>(self)</dt></dl>
 
@@ -185,7 +186,7 @@ Data descriptors inherited from <a href="ranger.shared.html#Awareness">ranger.sh
 </dl>
 <hr>
 Data and other attributes inherited from <a href="ranger.shared.settings.html#SettingsAware">ranger.shared.settings.SettingsAware</a>:<br>
-<dl><dt><strong>settings</strong> = &lt;ranger.ext.openstruct.OpenStruct object at 0x7f6a9067fbd0&gt;</dl>
+<dl><dt><strong>settings</strong> = &lt;ranger.ext.openstruct.OpenStruct object at 0xe2f090&gt;</dl>
 
 </td></tr></table></td></tr></table>
 </body></html>
\ No newline at end of file
lass="w"> # pointless in practice. So importing stubs is fine here! # check if we have already a symbol of the same name: var check = strTableGet(c.importTable.symbols, s.name) if check != nil and check.id != s.id: if s.kind notin OverloadableSyms or check.kind notin OverloadableSyms: # s and check need to be qualified: incl(c.ambiguousSymbols, s.id) incl(c.ambiguousSymbols, check.id) # thanks to 'export' feature, it could be we import the same symbol from # multiple sources, so we need to call 'StrTableAdd' here: strTableAdd(c.importTable.symbols, s) if s.kind == skType: var etyp = s.typ if etyp.kind in {tyBool, tyEnum}: for j in countup(0, sonsLen(etyp.n) - 1): var e = etyp.n.sons[j].sym if e.kind != skEnumField: internalError(c.config, s.info, "rawImportSymbol") # BUGFIX: because of aliases for enums the symbol may already # have been put into the symbol table # BUGFIX: but only iff they are the same symbols! var it: TIdentIter check = initIdentIter(it, c.importTable.symbols, e.name) while check != nil: if check.id == e.id: e = nil break check = nextIdentIter(it, c.importTable.symbols) if e != nil: if sfPure notin s.flags: rawImportSymbol(c, e) else: importPureEnumField(c, e) else: # rodgen assures that converters and patterns are no stubs if s.kind == skConverter: addConverter(c, s) if hasPattern(s): addPattern(c, s) proc importSymbol(c: PContext, n: PNode, fromMod: PSym) = let ident = lookups.considerQuotedIdent(c, n) let s = strTableGet(fromMod.tab, ident) if s == nil: errorUndeclaredIdentifier(c, n.info, ident.s) else: when false: if s.kind == skStub: loadStub(s) if s.kind notin ExportableSymKinds: internalError(c.config, n.info, "importSymbol: 2") # for an enumeration we have to add all identifiers case s.kind of skProcKinds: # for a overloadable syms add all overloaded routines var it: TIdentIter var e = initIdentIter(it, fromMod.tab, s.name) while e != nil: if e.name.id != s.name.id: internalError(c.config, n.info, "importSymbol: 3") rawImportSymbol(c, e) e = nextIdentIter(it, fromMod.tab) else: rawImportSymbol(c, s) suggestSym(c.config, n.info, s, c.graph.usageSym, false) proc importAllSymbolsExcept(c: PContext, fromMod: PSym, exceptSet: IntSet) = var i: TTabIter var s = initTabIter(i, fromMod.tab) while s != nil: if s.kind != skModule: if s.kind != skEnumField: if s.kind notin ExportableSymKinds: internalError(c.config, s.info, "importAllSymbols: " & $s.kind & " " & s.name.s) if exceptSet.isNil or s.name.id notin exceptSet: rawImportSymbol(c, s) s = nextIter(i, fromMod.tab) proc importAllSymbols*(c: PContext, fromMod: PSym) = var exceptSet: IntSet importAllSymbolsExcept(c, fromMod, exceptSet) proc importForwarded(c: PContext, n: PNode, exceptSet: IntSet) = if n.isNil: return case n.kind of nkExportStmt: for a in n: assert a.kind == nkSym let s = a.sym if s.kind == skModule: importAllSymbolsExcept(c, s, exceptSet) elif exceptSet.isNil or s.name.id notin exceptSet: rawImportSymbol(c, s) of nkExportExceptStmt: localError(c.config, n.info, "'export except' not implemented") else: for i in 0..safeLen(n)-1: importForwarded(c, n.sons[i], exceptSet) proc importModuleAs(c: PContext; n: PNode, realModule: PSym): PSym = result = realModule if n.kind != nkImportAs: discard elif n.len != 2 or n.sons[1].kind != nkIdent: localError(c.config, n.info, "module alias must be an identifier") elif n.sons[1].ident.id != realModule.name.id: # some misguided guy will write 'import abc.foo as foo' ... result = createModuleAlias(realModule, n.sons[1].ident, realModule.info, c.config.options) proc myImportModule(c: PContext, n: PNode; importStmtResult: PNode): PSym = let f = checkModuleName(c.config, n) if f != InvalidFileIDX: let L = c.graph.importStack.len let recursion = c.graph.importStack.find(f) c.graph.importStack.add f #echo "adding ", toFullPath(f), " at ", L+1 if recursion >= 0: var err = "" for i in countup(recursion, L-1): if i > recursion: err.add "\n" err.add toFullPath(c.config, c.graph.importStack[i]) & " imports " & toFullPath(c.config, c.graph.importStack[i+1]) c.recursiveDep = err result = importModuleAs(c, n, c.graph.importModuleCallback(c.graph, c.module, f)) #echo "set back to ", L c.graph.importStack.setLen(L) # we cannot perform this check reliably because of # test: modules/import_in_config) when true: if result.info.fileIndex == c.module.info.fileIndex and result.info.fileIndex == n.info.fileIndex: localError(c.config, n.info, "A module cannot import itself") if sfDeprecated in result.flags: if result.constraint != nil: message(c.config, n.info, warnDeprecated, result.constraint.strVal & "; " & result.name.s) else: message(c.config, n.info, warnDeprecated, result.name.s) suggestSym(c.config, n.info, result, c.graph.usageSym, false) importStmtResult.add newSymNode(result, n.info) #newStrNode(toFullPath(c.config, f), n.info) proc transformImportAs(c: PContext; n: PNode): PNode = if n.kind == nkInfix and considerQuotedIdent(c, n[0]).s == "as": result = newNodeI(nkImportAs, n.info) result.add n.sons[1] result.add n.sons[2] else: result = n proc impMod(c: PContext; it: PNode; importStmtResult: PNode) = let it = transformImportAs(c, it) let m = myImportModule(c, it, importStmtResult) if m != nil: var emptySet: IntSet # ``addDecl`` needs to be done before ``importAllSymbols``! addDecl(c, m, it.info) # add symbol to symbol table of module importAllSymbolsExcept(c, m, emptySet) #importForwarded(c, m.ast, emptySet) proc evalImport*(c: PContext, n: PNode): PNode = result = newNodeI(nkImportStmt, n.info) for i in countup(0, sonsLen(n) - 1): let it = n.sons[i] if it.kind == nkInfix and it.len == 3 and it[2].kind == nkBracket: let sep = it[0] let dir = it[1] var imp = newNodeI(nkInfix, it.info) imp.add sep imp.add dir imp.add sep # dummy entry, replaced in the loop for x in it[2]: # transform `a/b/[c as d]` to `/a/b/c as d` if x.kind == nkInfix and x.sons[0].ident.s == "as": let impAs = copyTree(x) imp.sons[2] = x.sons[1] impAs.sons[1] = imp impMod(c, imp, result) else: imp.sons[2] = x impMod(c, imp, result) else: impMod(c, it, result) proc evalFrom*(c: PContext, n: PNode): PNode = result = newNodeI(nkImportStmt, n.info) checkMinSonsLen(n, 2, c.config) n.sons[0] = transformImportAs(c, n.sons[0]) var m = myImportModule(c, n.sons[0], result) if m != nil: n.sons[0] = newSymNode(m) addDecl(c, m, n.info) # add symbol to symbol table of module for i in countup(1, sonsLen(n) - 1): if n.sons[i].kind != nkNilLit: importSymbol(c, n.sons[i], m) proc evalImportExcept*(c: PContext, n: PNode): PNode = result = newNodeI(nkImportStmt, n.info) checkMinSonsLen(n, 2, c.config) n.sons[0] = transformImportAs(c, n.sons[0]) var m = myImportModule(c, n.sons[0], result) if m != nil: n.sons[0] = newSymNode(m) addDecl(c, m, n.info) # add symbol to symbol table of module importAllSymbolsExcept(c, m, readExceptSet(c, n)) #importForwarded(c, m.ast, exceptSet)