[Sciviews-commits] r425 - in komodo/SciViews-K-dev: . R components content content/js skin skin/images

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Mon Feb 6 18:58:24 CET 2012


Author: prezez
Date: 2012-02-06 18:58:24 +0100 (Mon, 06 Feb 2012)
New Revision: 425

Added:
   komodo/SciViews-K-dev/skin/images/r_16x16.png
Modified:
   komodo/SciViews-K-dev/R/.Rprofile
   komodo/SciViews-K-dev/components/koR_UDL_Language.py
   komodo/SciViews-K-dev/content/js/sciviews.js
   komodo/SciViews-K-dev/content/overlayMain.xul
   komodo/SciViews-K-dev/install.rdf
   komodo/SciViews-K-dev/skin/sciviewsk.css
Log:
sciviewsk-dev: changes for compatibility with Komodo 7
console output, R toolbar, KoRLanguage object, R language icon.

Modified: komodo/SciViews-K-dev/R/.Rprofile
===================================================================
--- komodo/SciViews-K-dev/R/.Rprofile	2012-02-01 11:06:44 UTC (rev 424)
+++ komodo/SciViews-K-dev/R/.Rprofile	2012-02-06 17:58:24 UTC (rev 425)
@@ -1,160 +1,160 @@
-options(json.method="R")
-
-if(existsFunction("stopAllConnections")) stopAllConnections()
-if(existsFunction("stopAllServers")) stopAllServers()
-
-
-if("komodoConnection" %in% search()) detach("komodoConnection")
-attach(new.env(), name="komodoConnection")
-
-with(as.environment("komodoConnection"), {
-
-	#`svOption` <- function (arg.name, default = NA, as.type = as.character, ...) {
-	#	args <- gsub("\\b-\\b", ".", commandArgs(trailingOnly=TRUE))
-	#
-	#	pfx <- paste("^--", arg.name, "=", sep = "")
-	#	x <- args[grep(pfx, args)]
-	#
-	#	x <- if (!length(x)) default else sub(pfx, "", x)
-	#	x <- as.type(x, ...)
-	#	x <- structure(list(x), names = arg.name)
-	#	do.call("options", x)
-	#	return(x)
-	#}
-
-	`svPager` <- function (files, header, title, delete.file) {
-		files <- gsub("\\", "\\\\", files[1], fixed = TRUE)
-		tryCatch(koCmd(sprintf('sv.r.pager("%1$s", "%2$s", %3$s)',
-			 files, title, if (delete.file) 'true' else 'false')),
-			error=function(e) browseURL(files, NULL))
-	}
-
-	`svBrowser` <- function(url) {
-		url <- gsub("\\", "\\\\", url, fixed = TRUE)
-		## If the URL starts with '/', assume a file path
-		## on Unix or Mac and prepend 'file://'
-		url <- sub("^/", "file:///", url)
-		tryCatch(koCmd(sprintf("sv.command.openHelp(\"%s\")", url)),
-			warning=function(e) browseURL(url, NULL)
-			)
-	}
-
-	local({
-		require(utils)
-		`readline` <- function (prompt = "")
-			paste(koCmd(sprintf("ko.dialogs.prompt('%s', '', '', 'R asked a question', 'R-readline')", prompt),
-			timeout=0), collapse=" ")
-		unlockBinding("readline", env=baseenv())
-		bindingIsLocked("readline", env=baseenv())
-		assign("readline", value=readline, envir = baseenv())
-		utils::assignInNamespace("readline", value=readline, ns="base")
-		lockBinding("readline", env=baseenv())
-	})
-
-	options(browser = svBrowser, pager = svPager)
-
-	# a way round to get the url:
-	#getHelpURL(help("anova")) <- old syntax
-	#getHelpURL("anova") <- new syntax
-	`getHelpURL` <- function(..., help_type = "html") {
-		if(tools:::httpdPort == 0) suppressMessages(tools:::startDynamicHelp(TRUE))
-		help_type <- "html"
-		ret <- NULL
-		oBrowser <- options(browser=function(url) ret <<- url)
-		on.exit(options(oBrowser))
-		if(mode((cl <- match.call())[[2]][[1]]) == "name") { # handle old syntax
-			cl <- cl[[2]]
-			cl$help_type <- help_type
-			print(eval(cl, .GlobalEnv))
-		} else {
-			print(utils::help(..., help_type = help_type))
-		}
-		ret
-	}
-
-	require(utils)
-	require(stats)
-
-
-	env <- as.environment("komodoConnection")
-	src <- dir(pattern="\\.R$")
-	lapply(src[src != "init.R"], sys.source, envir=env)
-	invisible()
-})
-
-
-
-#svOption("ko.port", as.type=as.numeric)
-#svOption("ko.host", default="localhost")
-
-.Last <- function() {
-	try({
-	stopAllServers()
-	stopAllConnections()
-	})
-}
-
-
-local({
-
-port <- 1111L
-while((port < 1115L) && (as.character(startServer(port)) == "0")) port <- port + 1L
-
-cwd0 <- normalizePath(".")
-
-#cat("cwd0 is ", sQuote(getwd()), "\n")
-
-if(file.exists("init.R")) source("init.R")
-
-Rservers <- enumServers()
-if(is.numeric(getOption("ko.port")) && length(Rservers) > 0) {
-	cat("Server started at port", Rservers, "\n")
-	invisible(koCmd(paste(
-		"sv.cmdout.clear()",
-		#"sv.cmdout.append('R is started')",
-		sprintf("sv.cmdout.append('%s is started')", R.version.string),
-		"sv.command.updateRStatus(true)",
-		sprintf("sv.pref.setPref('sciviews.r.port', %s)", tail(Rservers, 1)),
-		sep = ";")))
-}
-
-cat("cwd is now ", sQuote(getwd()), "\n")
-
-## Do we have a .Rprofile file to source?
-#rprofile <- file.path(c(getwd(), Sys.getenv("R_USER")), ".Rprofile")
-cwd <- normalizePath(getwd())
-isBaseDir <- file.exists(file.path(cwd, "sv-basedir")) || (cwd == cwd0)
-rprofile <- file.path(c(if(!isBaseDir) getwd(), Sys.getenv("R_USER")), ".Rprofile")
-rprofile <- rprofile[file.exists(rprofile)][1]
-
-if (!is.na(rprofile)) {
-	source(rprofile)
-	cat("Loaded file:", rprofile, "\n")
-}
-
-if(.Platform$GUI == "Rgui" && file.exists("Rconsole"))
-	utils:::loadRconsole("Rconsole")
-
-
-if(!any(c("--vanilla", "--no-restore", "--no-restore-data") %in% commandArgs())
-	&& file.exists(".RData")) {
-	#sys.load.image(".RData", FALSE)
-}
-if(file.exists(".Rhistory")) loadhistory(".Rhistory")
-
-
-#obj <- ls(.GlobalEnv)
-#conflictObjs <- obj[obj %in% ls("komodoConnection")]
-#
-#if(length(conflictObjs) > 0) {
-#	cat("Following objects in .GlobalEnv were conflicting and  should be removed: \n")
-#	cat(sQuote(conflictObjs), "\n")
-#	rm(list=conflictObjs, envir=.GlobalEnv, inherits=FALSE)
-#}
-
-
-})
-
-#with(as.environment("komodoConnection"), {
-#rm(getHelpURL,  envir=.GlobalEnv)
-#})
+options(json.method="R")
+
+if(existsFunction("stopAllConnections")) stopAllConnections()
+if(existsFunction("stopAllServers")) stopAllServers()
+
+
+if("komodoConnection" %in% search()) detach("komodoConnection")
+attach(new.env(), name="komodoConnection")
+
+with(as.environment("komodoConnection"), {
+
+	#`svOption` <- function (arg.name, default = NA, as.type = as.character, ...) {
+	#	args <- gsub("\\b-\\b", ".", commandArgs(trailingOnly=TRUE))
+	#
+	#	pfx <- paste("^--", arg.name, "=", sep = "")
+	#	x <- args[grep(pfx, args)]
+	#
+	#	x <- if (!length(x)) default else sub(pfx, "", x)
+	#	x <- as.type(x, ...)
+	#	x <- structure(list(x), names = arg.name)
+	#	do.call("options", x)
+	#	return(x)
+	#}
+
+	`svPager` <- function (files, header, title, delete.file) {
+		files <- gsub("\\", "\\\\", files[1], fixed = TRUE)
+		tryCatch(koCmd(sprintf('sv.r.pager("%1$s", "%2$s", %3$s)',
+			 files, title, if (delete.file) 'true' else 'false')),
+			error=function(e) browseURL(files, NULL))
+	}
+
+	`svBrowser` <- function(url) {
+		url <- gsub("\\", "\\\\", url, fixed = TRUE)
+		## If the URL starts with '/', assume a file path
+		## on Unix or Mac and prepend 'file://'
+		url <- sub("^/", "file:///", url)
+		tryCatch(koCmd(sprintf("sv.command.openHelp(\"%s\")", url)),
+			warning=function(e) browseURL(url, NULL)
+			)
+	}
+
+	local({
+		require(utils)
+		`readline` <- function (prompt = "")
+			paste(koCmd(sprintf("ko.dialogs.prompt('%s', '', '', 'R asked a question', 'R-readline')", prompt),
+			timeout=0), collapse=" ")
+		unlockBinding("readline", env=baseenv())
+		bindingIsLocked("readline", env=baseenv())
+		assign("readline", value=readline, envir = baseenv())
+		utils::assignInNamespace("readline", value=readline, ns="base")
+		lockBinding("readline", env=baseenv())
+	})
+
+	options(browser = svBrowser, pager = svPager)
+
+	# a way round to get the url:
+	#getHelpURL(help("anova")) <- old syntax
+	#getHelpURL("anova") <- new syntax
+	`getHelpURL` <- function(..., help_type = "html") {
+		if(tools:::httpdPort == 0) suppressMessages(tools:::startDynamicHelp(TRUE))
+		help_type <- "html"
+		ret <- NULL
+		oBrowser <- options(browser=function(url) ret <<- url)
+		on.exit(options(oBrowser))
+		if(mode((cl <- match.call())[[2]][[1]]) == "name") { # handle old syntax
+			cl <- cl[[2]]
+			cl$help_type <- help_type
+			print(eval(cl, .GlobalEnv))
+		} else {
+			print(utils::help(..., help_type = help_type))
+		}
+		ret
+	}
+
+	require(utils)
+	require(stats)
+
+	env <- as.environment("komodoConnection")
+	src <- dir(pattern = "\\.R$")
+	lapply(src[src != "init.R"], sys.source, envir = env)
+	invisible()
+})
+
+
+
+#svOption("ko.port", as.type=as.numeric)
+#svOption("ko.host", default="localhost")
+
+.Last <- function() {
+	try({
+	stopAllServers()
+	stopAllConnections()
+	})
+}
+
+
+local({
+
+port <- 1111L
+while((port < 1115L) && (as.character(startServer(port)) == "0")) port <- port + 1L
+
+cwd0 <- normalizePath(".")
+
+#cat("cwd0 is ", sQuote(getwd()), "\n")
+
+if(file.exists("init.R")) source("init.R")
+
+Rservers <- enumServers()
+if(is.numeric(getOption("ko.port")) && length(Rservers) > 0) {
+	cat("Server started at port", Rservers, "\n")
+	invisible(koCmd(paste(
+		"sv.cmdout.clear()",
+		#"sv.cmdout.append('R is started')",
+		sprintf("sv.cmdout.append('%s is started')", R.version.string),
+		"sv.command.updateRStatus(true)",
+		sprintf("sv.pref.setPref('sciviews.r.port', %s)", tail(Rservers, 1)),
+		sep = ";")))
+}
+
+cat("cwd is now ", sQuote(getwd()), "\n")
+
+## Do we have a .Rprofile file to source?
+#rprofile <- file.path(c(getwd(), Sys.getenv("R_USER")), ".Rprofile")
+cwd <- normalizePath(getwd())
+isBaseDir <- file.exists(file.path(cwd, "sv-basedir")) || (cwd == cwd0)
+rprofile <- file.path(c(if(!isBaseDir) getwd(), Sys.getenv("R_USER")), ".Rprofile")
+rprofile <- rprofile[file.exists(rprofile)][1]
+
+if (!is.na(rprofile)) {
+	source(rprofile)
+	cat("Loaded file:", rprofile, "\n")
+}
+
+if(.Platform$GUI == "Rgui") {
+	if(file.exists("Rconsole"))	utils:::loadRconsole("Rconsole")
+	utils::setWindowTitle("talking to Komodo")
+}
+
+if(!any(c("--vanilla", "--no-restore", "--no-restore-data") %in% commandArgs())
+	&& file.exists(".RData")) {
+	#sys.load.image(".RData", FALSE)
+}
+if(file.exists(".Rhistory")) loadhistory(".Rhistory")
+
+
+#obj <- ls(.GlobalEnv)
+#conflictObjs <- obj[obj %in% ls("komodoConnection")]
+#
+#if(length(conflictObjs) > 0) {
+#	cat("Following objects in .GlobalEnv were conflicting and  should be removed: \n")
+#	cat(sQuote(conflictObjs), "\n")
+#	rm(list=conflictObjs, envir=.GlobalEnv, inherits=FALSE)
+#}
+
+
+})
+
+#with(as.environment("komodoConnection"), {
+#rm(getHelpURL,  envir=.GlobalEnv)
+#})

Modified: komodo/SciViews-K-dev/components/koR_UDL_Language.py
===================================================================
--- komodo/SciViews-K-dev/components/koR_UDL_Language.py	2012-02-01 11:06:44 UTC (rev 424)
+++ komodo/SciViews-K-dev/components/koR_UDL_Language.py	2012-02-06 17:58:24 UTC (rev 425)
@@ -54,8 +54,9 @@
     _reg_desc_ = "%s Language" % name
     _reg_contractid_ = "@activestate.com/koLanguage?language=%s;1" % name
     _reg_clsid_ = "{4cc23d3b-52e2-426d-8a22-6d7eb2ba81ae}"
+    _reg_categories_ = [("komodo-language", name)]
     defaultExtension = '.R'
-
+    primary = 1
     lang_from_udl_family = {
         'SSL': 'R'
     }
@@ -69,7 +70,7 @@
 
     variableIndicators = '$'
     _dedenting_statements = [u'return', u'break', u'else', u'next']
-    _indenting_statements = [u'switch', u'if', u'ifelse', u'while', u'for', u'repeat']
+    _indenting_statements = [u'switch', u'if', u'ifelse', u'while', u'for', u'repeat', u'break']
     supportsSmartIndent = "brace"
 
     #styleStdin = components.interfaces.ISciMoz.SCE_C_STDIN
@@ -125,134 +126,134 @@
     #    return self._lexer
 
 
-import re
-from koLanguageServiceBase import *
+# import re
+# from koLanguageServiceBase import *
 
-iface = components.interfaces.koICodeIntelCompletionUIHandler
+# iface = components.interfaces.koICodeIntelCompletionUIHandler
 
-#log = logging.getLogger("koRCompletion")
-class KoRCompletion(KoCompletionLanguageService):
-    _com_interfaces_ = [components.interfaces.koICompletionLanguageService]
-    _reg_desc_       = "R Calltip/AutoCompletion Service"
-    _reg_clsid_      = "{DF19E793-ECC2-6571-7CC1-D7F02D1C94C7}"
-    _reg_contractid_ = "@sciviews.org/koRCompletionLanguageService;1"
+# #log = logging.getLogger("koRCompletion")
+# class KoRCompletion(KoCompletionLanguageService):
+    # _com_interfaces_ = [components.interfaces.koICompletionLanguageService]
+    # _reg_desc_       = "R Calltip/AutoCompletion Service"
+    # _reg_clsid_      = "{DF19E793-ECC2-6571-7CC1-D7F02D1C94C7}"
+    # _reg_contractid_ = "@sciviews.org/koRCompletionLanguageService;1"
 
-    #useCharSet = "_: " + string.ascii_uppercase + string.ascii_lowercase + string.digits
+    # #useCharSet = "_: " + string.ascii_uppercase + string.ascii_lowercase + string.digits
 
-    def __init__(self):
-        self._ok = 1
-        self.triggersCallTip = '('
-        self.triggers = ''
-        self.completionSeparator = ord('\n')
-        self._scintilla = None
-        self._lastlComplete = []
-        self._lastcompletion = None
-        self.sv_utils = components.classes["@sciviews.org/svUtils;1"].\
-            getService(components.interfaces.svIUtils)
-        log.debug("KoRCompletion __init__")
+    # def __init__(self):
+        # self._ok = 1
+        # self.triggersCallTip = '('
+        # self.triggers = ''
+        # self.completionSeparator = ord('\n')
+        # self._scintilla = None
+        # self._lastlComplete = []
+        # self._lastcompletion = None
+        # self.sv_utils = components.classes["@sciviews.org/svUtils;1"].\
+            # getService(components.interfaces.svIUtils)
+        # log.debug("KoRCompletion __init__")
 
 
-    def _get_code_frag(self, scimoz):
-        # Get sensible code fragment
-        cur_pos = scimoz.currentPos
-        cur_line = scimoz.lineFromPosition(cur_pos)
-        pos_start = scimoz.positionFromLine(scimoz.getFoldParent(cur_line))
-        pos_end = max(scimoz.anchor, cur_pos)
-        text = scimoz.getTextRange(pos_start, pos_end)
-        return text
+    # def _get_code_frag(self, scimoz):
+        # # Get sensible code fragment
+        # cur_pos = scimoz.currentPos
+        # cur_line = scimoz.lineFromPosition(cur_pos)
+        # pos_start = scimoz.positionFromLine(scimoz.getFoldParent(cur_line))
+        # pos_end = max(scimoz.anchor, cur_pos)
+        # text = scimoz.getTextRange(pos_start, pos_end)
+        # return text
 
 
-    def _getCompletions(self, text):
-        if not text.strip(): return 0, None
-        cmd = 'completion("%s", print=TRUE, types="scintilla", field.sep="?")' \
-            % text.replace('"', '\\"')
-        compl_str = self.sv_utils.execInR(cmd, "h")
+    # def _getCompletions(self, text):
+        # if not text.strip(): return 0, None
+        # cmd = 'completion("%s", print=TRUE, types="scintilla", field.sep="?")' \
+            # % text.replace('"', '\\"')
+        # compl_str = self.sv_utils.execInR(cmd, "h")
 
-        if ((compl_str == '') or (re.search("^\d+[\r\n]", compl_str) == None)):
-            return 0, None
+        # if ((compl_str == '') or (re.search("^\d+[\r\n]", compl_str) == None)):
+            # return 0, None
 
-        compl_str = re.split("[\r\n]+", compl_str.replace('\r\n', chr(self.completionSeparator)), 1)
-        trig_len = int(compl_str[0])
-        compl_str = compl_str[1]
-        return trig_len, compl_str
+        # compl_str = re.split("[\r\n]+", compl_str.replace('\r\n', chr(self.completionSeparator)), 1)
+        # trig_len = int(compl_str[0])
+        # compl_str = compl_str[1]
+        # return trig_len, compl_str
 
-    def _getTip(self, text):
-        cmd = 'cat(callTip("%s", location=TRUE, description=TRUE, methods=TRUE, width=80))' \
-            % text.replace('"', '\\"')
-        result = self.sv_utils.execInR(cmd, "h").strip()
-        #if not result: return None
-        result = result.replace('[\r\n]+', '\n')
-        return result
+    # def _getTip(self, text):
+        # cmd = 'cat(callTip("%s", location=TRUE, description=TRUE, methods=TRUE, width=80))' \
+            # % text.replace('"', '\\"')
+        # result = self.sv_utils.execInR(cmd, "h").strip()
+        # #if not result: return None
+        # result = result.replace('[\r\n]+', '\n')
+        # return result
 
-    def _DoTipComplete(self):
-        s = self._scintilla
-        #s.autoCCancelAtStart = 0
-        text = self._get_code_frag(s)
-        if len(text) < 3:
-            if s.autoCActive(): s.autoCCancel()
-            return
-        tip_str = self._getTip(text)
-        if tip_str:
-            self._scintilla.callTipShow(s.currentPos, tip_str)
-        elif s.autoCActive():
-            s.autoCCancel()
+    # def _DoTipComplete(self):
+        # s = self._scintilla
+        # #s.autoCCancelAtStart = 0
+        # text = self._get_code_frag(s)
+        # if len(text) < 3:
+            # if s.autoCActive(): s.autoCCancel()
+            # return
+        # tip_str = self._getTip(text)
+        # if tip_str:
+            # self._scintilla.callTipShow(s.currentPos, tip_str)
+        # elif s.autoCActive():
+            # s.autoCCancel()
 
-    def AutoComplete(self, ch, scimoz):
-        log.debug("KoRCompletion AutoComplete")
-        if not self._ok: return
-        s = self._scintilla = scimoz
-        text = self._get_code_frag(s)
-        trig_len, completions =self._getCompletions(text)
-        if not completions: return
+    # def AutoComplete(self, ch, scimoz):
+        # log.debug("KoRCompletion AutoComplete")
+        # if not self._ok: return
+        # s = self._scintilla = scimoz
+        # text = self._get_code_frag(s)
+        # trig_len, completions =self._getCompletions(text)
+        # if not completions: return
 
-        if s.callTipActive():
-            s.callTipCancel()
-        scimoz.autoCShow(trig_len, completions)
+        # if s.callTipActive():
+            # s.callTipCancel()
+        # scimoz.autoCShow(trig_len, completions)
 
-    def StartCallTip(self, ch, scimoz):
-        log.debug("KoRCompletion StartCallTip")
-        if not self._ok: return
-        s = self._scintilla = scimoz
+    # def StartCallTip(self, ch, scimoz):
+        # log.debug("KoRCompletion StartCallTip")
+        # if not self._ok: return
+        # s = self._scintilla = scimoz
 
-        #s.SCE_UDL_SSL_COMMENT, s.SCE_UDL_SSL_STRING, SCE_UDL_SSL_DEFAULT
+        # #s.SCE_UDL_SSL_COMMENT, s.SCE_UDL_SSL_STRING, SCE_UDL_SSL_DEFAULT
 
-        # Only do this if we have no selection
-        if s.selectionStart == s.selectionEnd and s.selectionStart > 0:
-            curPos = s.positionBefore(s.currentPos)
-            style  = s.getStyleAt(curPos)
-            if style == s.SCE_UDL_SSL_COMMENT: return
-            if style == s.SCE_UDL_SSL_STRING: return
+        # # Only do this if we have no selection
+        # if s.selectionStart == s.selectionEnd and s.selectionStart > 0:
+            # curPos = s.positionBefore(s.currentPos)
+            # style  = s.getStyleAt(curPos)
+            # if style == s.SCE_UDL_SSL_COMMENT: return
+            # if style == s.SCE_UDL_SSL_STRING: return
 
-            if s.callTipActive(): return
-            else:
-                self._DoTipComplete()
-                return
+            # if s.callTipActive(): return
+            # else:
+                # self._DoTipComplete()
+                # return
 
-        if s.autoCActive(): s.autoCCancel()
+        # if s.autoCActive(): s.autoCCancel()
 
 
-class KoRCodeIntelCompletionLanguageService(KoCodeIntelCompletionLanguageService):
-    _com_interfaces_ = [components.interfaces.koICodeIntelCompletionLanguageService]
-    _reg_desc_ = "R CodeIntel Calltip/AutoCompletion Service"
-    _reg_clsid_ = "{E9C1237A-D3F4-2AE2-EF66-02D3C30D3678}"
-    _reg_contractid_ = "@sciviews.org/koRCodeIntelCompletionLanguageService;1"
+# class KoRCodeIntelCompletionLanguageService(KoCodeIntelCompletionLanguageService):
+    # _com_interfaces_ = [components.interfaces.koICodeIntelCompletionLanguageService]
+    # _reg_desc_ = "R CodeIntel Calltip/AutoCompletion Service"
+    # _reg_clsid_ = "{E9C1237A-D3F4-2AE2-EF66-02D3C30D3678}"
+    # _reg_contractid_ = "@sciviews.org/koRCodeIntelCompletionLanguageService;1"
 
-    # Characters that should automatically invoke the current completion item
-    # - cannot be '-' for "autocomplete-*-subs" because:
-    #       attributes::->import(__PACKAGE__, \$x, 'Bent');
-    # - cannot be '{' for "autocomplete-object-subs" because:
-    #       my $d = $self->{'escape'};
-    # - shouldn't be ')' because:
-    #       $dumper->dumpValue(\*::);
-    completionFillups = "@$([]"
+    # # Characters that should automatically invoke the current completion item
+    # # - cannot be '-' for "autocomplete-*-subs" because:
+    # #       attributes::->import(__PACKAGE__, \$x, 'Bent');
+    # # - cannot be '{' for "autocomplete-object-subs" because:
+    # #       my $d = $self->{'escape'};
+    # # - shouldn't be ')' because:
+    # #       $dumper->dumpValue(\*::);
+    # completionFillups = "@$([]"
 
-    def __init__(self):
-        KoCodeIntelCompletionLanguageService.__init__(self)
-        log.debug("KoRCICompletion... __init__")
+    # def __init__(self):
+        # KoCodeIntelCompletionLanguageService.__init__(self)
+        # log.debug("KoRCICompletion... __init__")
 
-    def triggerPrecedingCompletionUI(self, path, scimoz, startPos,
-                                     ciCompletionUtriggerPrecedingCompletionUI):
-        log.debug("KoRCICompletion... triggerPrecedingCompletionUI")
-        KoCodeIntelCompletionLanguageService(self, path, scimoz, startPos,
-                                     ciCompletionUtriggerPrecedingCompletionUI)
-        pass
+    # def triggerPrecedingCompletionUI(self, path, scimoz, startPos,
+                                     # ciCompletionUtriggerPrecedingCompletionUI):
+        # log.debug("KoRCICompletion... triggerPrecedingCompletionUI")
+        # KoCodeIntelCompletionLanguageService(self, path, scimoz, startPos,
+                                     # ciCompletionUtriggerPrecedingCompletionUI)
+        # pass

Modified: komodo/SciViews-K-dev/content/js/sciviews.js
===================================================================
--- komodo/SciViews-K-dev/content/js/sciviews.js	2012-02-01 11:06:44 UTC (rev 424)
+++ komodo/SciViews-K-dev/content/js/sciviews.js	2012-02-06 17:58:24 UTC (rev 425)
@@ -671,8 +671,13 @@
 this.__defineGetter__('eolChar', function()
 	["\r\n", "\n", "\r"][_this.scimoz.eOLMode]);
 
-this.__defineGetter__('scimoz', function()
-	document.getElementById("runoutput-scintilla").scimoz);
+this.__defineGetter__('scimoz', function() {
+	if(window.frames["runoutput-desc-tabpanel"]) // Komodo 7
+		return window.frames["runoutput-desc-tabpanel"]
+			.document.getElementById("runoutput-scintilla").scimoz;
+	else
+		return document.getElementById("runoutput-scintilla").scimoz;
+});
 
 
 function _rgb(r, g, b) {
@@ -781,8 +786,12 @@
 
 	if (scrollToStart === undefined) scrollToStart = false;
 
-	ko.uilayout.ensureOutputPaneShown();
-	ko.uilayout.ensureTabShown("runoutput_tab", false);
+	try {
+		ko.uilayout.ensureOutputPaneShown();
+		ko.uilayout.ensureTabShown("runoutput_tab", false);
+	} catch(e) { // Komodo 7
+		ko.run.output.show();
+	}
 
 	str = fixEOL(str);
 
@@ -895,8 +904,15 @@
 }
 // Display message on the status bar (default) or command output bar
 this.message = function (msg, timeout, highlight) {
-	document.getElementById('output_tabpanels').selectedIndex = 0;
-	var runoutputDesc = document.getElementById('runoutput-desc');
+	try {
+		ko.uilayout.ensureOutputPaneShown();
+		ko.uilayout.ensureTabShown("runoutput_tab", false);
+	} catch(e) { // Komodo 7
+		ko.run.output.show();
+	}
+	var win = (window.frames["runoutput-desc-tabpanel"])?
+		window.frames["runoutput-desc-tabpanel"] : window;
+	var runoutputDesc = win.document.getElementById('runoutput-desc');
 	if (msg == null) msg = "";
 	runoutputDesc.parentNode.style.backgroundColor =
 		(highlight && msg) ? "highlight" : "";

Modified: komodo/SciViews-K-dev/content/overlayMain.xul
===================================================================
--- komodo/SciViews-K-dev/content/overlayMain.xul	2012-02-01 11:06:44 UTC (rev 424)
+++ komodo/SciViews-K-dev/content/overlayMain.xul	2012-02-06 17:58:24 UTC (rev 425)
@@ -243,13 +243,16 @@
 		</menu>
 	</menubar>
 
-	<toolbar id="main-toolboxrow">
-		<toolbaritem class="chromeclass-toolbar"
+	<toolboxrow id="main-toolboxrow">
+		<toolbar class="chromeclass-toolbar"
 			id="RToolbar"
+			toolboxid="toolbox_main"
 			broadcaster="cmd_viewrtoolbar"
 			grippyhidden="true"
 			align="center"
-			persist="hidden collapsed buttonstyle"
+			kohidden="true"
+			mode="icons"
+			persist="kohidden collapsed buttonstyle mode"
 			buttonstyle="pictures">
 			<toolbarbutton buttonstyle="pictures"
 						   tooltiptext="&rEscape;"
@@ -311,8 +314,8 @@
 						   class="r-source-function-icon"
 						   observes="cmd_svRSourceFunction"
 						   label="rSrcFun;" />
-		</toolbaritem>
-	</toolbar>
+		</toolbar>
+	</toolboxrow>
 
 	<menupopup id="context-toolbox-menu">
 		<menuitem id="context_viewrtoolbar"

Modified: komodo/SciViews-K-dev/install.rdf
===================================================================
--- komodo/SciViews-K-dev/install.rdf	2012-02-01 11:06:44 UTC (rev 424)
+++ komodo/SciViews-K-dev/install.rdf	2012-02-06 17:58:24 UTC (rev 425)
@@ -2,9 +2,10 @@
 <RDF xmlns="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
      xmlns:em="http://www.mozilla.org/2004/em-rdf#">
     <Description about="urn:mozilla:install-manifest">
+		<em:unpack>true</em:unpack>
         <em:id>sciviewsk at sciviews.org</em:id>
         <em:name>SciViews-K</em:name>
-        <em:version>1.0.7dev</em:version>
+        <em:version>1.1.0dev</em:version>
         <em:description>Edit R code with Komodo</em:description>
         <em:creator>Philippe Grosjean</em:creator>
         <em:contributor>Romain Francois</em:contributor>
@@ -17,7 +18,7 @@
                 <!-- Komodo IDE's uuid -->
                 <em:id>{36E66FA0-F259-11D9-850E-000D935D3368}</em:id>
                 <em:minVersion>6.0</em:minVersion>
-                <em:maxVersion>6.*</em:maxVersion>
+                <em:maxVersion>7.*</em:maxVersion>
             </Description>
         </em:targetApplication>
         <em:targetApplication>
@@ -25,7 +26,7 @@
                 <!-- Komodo Edit's uuid -->
                 <em:id>{b1042fb5-9e9c-11db-b107-000d935d3368}</em:id>
                 <em:minVersion>6.0</em:minVersion>
-                <em:maxVersion>6.*</em:maxVersion>
+                <em:maxVersion>7.*</em:maxVersion>
             </Description>
         </em:targetApplication>
     </Description>

Added: komodo/SciViews-K-dev/skin/images/r_16x16.png
===================================================================
(Binary files differ)


Property changes on: komodo/SciViews-K-dev/skin/images/r_16x16.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Modified: komodo/SciViews-K-dev/skin/sciviewsk.css
===================================================================
--- komodo/SciViews-K-dev/skin/sciviewsk.css	2012-02-01 11:06:44 UTC (rev 424)
+++ komodo/SciViews-K-dev/skin/sciviewsk.css	2012-02-06 17:58:24 UTC (rev 425)
@@ -339,3 +339,10 @@
 #sciviews_robjects_filterbox.badRegEx {
 	color: #ea0000;
 }
+
+
+
+.languageicon[language="R"],
+treechildren::-moz-tree-image(LanguageR) {
+  list-style-image: url("chrome://sciviewsk/skin/images/r_16x16.png");
+}



More information about the Sciviews-commits mailing list