About: Continue omnicompletion for python modules   Sponge Permalink

An Entity of Type : owl:Thing, within Data Space : 134.155.108.49:8890 associated with source dataset(s)

In order to get completions for this module, one would have to either manually type to run the completion function again, or delete and then re-insert the period. The correct solution is, of course, to fix the Python omnicompletion module. However, this 'feature' is present in all default installations of Vim. imap pumvisible() ? "=(col('.')-1&&match(getline(line('.')), '\\.', \ col('.')-2) == col('.')-2)?\"\C-X>\C-O>\":\"\"" \ : ""

AttributesValues
rdfs:label
  • Continue omnicompletion for python modules
rdfs:comment
  • In order to get completions for this module, one would have to either manually type <c-x> <c-o></c-o> </c-x> to run the completion function again, or delete and then re-insert the period. The correct solution is, of course, to fix the Python omnicompletion module. However, this 'feature' is present in all default installations of Vim. imap pumvisible() ? "=(col('.')-1&&match(getline(line('.')), '\\.', \ col('.')-2) == col('.')-2)?\"\C-X>\C-O>\":\"\"" \ : ""
Version
  • 7(xsd:integer)
dbkwik:vim/property/wikiPageUsesTemplate
Previous
  • 1547(xsd:integer)
Category
  • Python
  • Omnicomplete
Author
  • ViPERPHiSH
Subpage
  • /200803
Complexity
  • basic
Created
  • 2008(xsd:integer)
ID
  • 1548(xsd:integer)
NEXT
  • 1549(xsd:integer)
abstract
  • In order to get completions for this module, one would have to either manually type <c-x> <c-o></c-o> </c-x> to run the completion function again, or delete and then re-insert the period. The correct solution is, of course, to fix the Python omnicompletion module. However, this 'feature' is present in all default installations of Vim. Here is a stopgap solution. On <cr></cr>, it accepts the current completion, and then runs a <c-r> = </c-r> expression that checks to see if the character before the cursor is a '.'. If it is, then it runs omnicomplete again. The tricky bit about this is that it needs to accept the completion before it can check the cursor position, or else it will be checking against the partially completed text. The col('.')-1 check avoids a problem where you return without a selected match which lands you at column 1 of the next line. imap pumvisible() ? "=(col('.')-1&&match(getline(line('.')), '\\.', \ col('.')-2) == col('.')-2)?\"\C-X>\C-O>\":\"\"" \ : ""
Alternative Linked Data Views: ODE     Raw Data in: CXML | CSV | RDF ( N-Triples N3/Turtle JSON XML ) | OData ( Atom JSON ) | Microdata ( JSON HTML) | JSON-LD    About   
This material is Open Knowledge   W3C Semantic Web Technology [RDF Data] Valid XHTML + RDFa
OpenLink Virtuoso version 07.20.3217, on Linux (x86_64-pc-linux-gnu), Standard Edition
Data on this page belongs to its respective rights holders.
Virtuoso Faceted Browser Copyright © 2009-2012 OpenLink Software