]> git.lyx.org Git - lyx.git/blobdiff - lib/configure.py
Put the InsetLayout default CSS stuff to use.
[lyx.git] / lib / configure.py
index a8a9cdb2beb326d890fad35e616eb983591dd06c..3fe21a5c7aa87caf7c3038d946243bc9b5a0e289 100644 (file)
@@ -206,6 +206,8 @@ def checkProgAlternatives(description, progs, rc_entry = [], alt_rc_entry = [],
             for ext in extlist:
                 if os.path.isfile( os.path.join(ac_dir, ac_word + ext) ):
                     logger.info(msg + ' yes')
+                    pr = re.compile(r'(\\\S+)(.*)$')
+                    m = None
                     # write rc entries for this command
                     if found_prime == False:
                         if len(rc_entry) == 1:
@@ -219,13 +221,17 @@ def checkProgAlternatives(description, progs, rc_entry = [], alt_rc_entry = [],
                         alt_rc = alt_rc_entry[0]
                         if alt_rc == "":
                             # if no explicit alt_rc is given, construct one
-                            alt_rc = rc_entry[0] + "_alternatives"
+                            m = pr.match(rc_entry[0])
+                            if m:
+                                alt_rc = m.group(1) + "_alternatives" + m.group(2)
                         addToRC(alt_rc.replace('%%', ac_prog))
                     elif len(alt_rc_entry) > 1:
                         alt_rc = alt_rc_entry[idx]
                         if alt_rc == "":
                             # if no explicit alt_rc is given, construct one
-                            alt_rc = rc_entry[idx] + "_alternatives"
+                            m = pr.match(rc_entry[idx])
+                            if m:
+                                alt_rc = m.group(1) + "_alternatives" + m.group(2)
                         addToRC(alt_rc.replace('%%', ac_prog))
                     found_alt = True
                     break
@@ -286,12 +292,10 @@ def checkViewer(description, progs, rc_entry = [], path = []):
     alt_rc_entry = []
     for idx in range(len(progs)):
         if len(rc_entry) == 1:
-            logger.info("rc_entry: " + rc_entry[0])
             rcs = rc_entry[0].split('\n')
             alt = addViewerAlternatives(rcs)
             alt_rc_entry.insert(0, alt)
         elif len(rc_entry) > 1:
-            logger.info("rc_entry: " + rc_entry[idx])
             rcs = rc_entry[idx].split('\n')
             alt = addViewerAlternatives(rcs)
             alt_rc_entry.insert(idx, alt)
@@ -306,12 +310,10 @@ def checkEditor(description, progs, rc_entry = [], path = []):
     alt_rc_entry = []
     for idx in range(len(progs)):
         if len(rc_entry) == 1:
-            logger.info("rc_entry: " + rc_entry[0])
             rcs = rc_entry[0].split('\n')
             alt = addEditorAlternatives(rcs)
             alt_rc_entry.insert(0, alt)
         elif len(rc_entry) > 1:
-            logger.info("rc_entry: " + rc_entry[idx])
             rcs = rc_entry[idx].split('\n')
             alt = addEditorAlternatives(rcs)
             alt_rc_entry.insert(idx, alt)
@@ -326,12 +328,10 @@ def checkViewerNoRC(description, progs, rc_entry = [], path = []):
     alt_rc_entry = []
     for idx in range(len(progs)):
         if len(rc_entry) == 1:
-            logger.info("rc_entry: " + rc_entry[0])
             rcs = rc_entry[0].split('\n')
             alt = addViewerAlternatives(rcs)
             alt_rc_entry.insert(0, alt)
         elif len(rc_entry) > 1:
-            logger.info("rc_entry: " + rc_entry[idx])
             rcs = rc_entry[idx].split('\n')
             alt = addViewerAlternatives(rcs)
             alt_rc_entry.insert(idx, alt)
@@ -347,12 +347,10 @@ def checkEditorNoRC(description, progs, rc_entry = [], path = []):
     alt_rc_entry = []
     for idx in range(len(progs)):
         if len(rc_entry) == 1:
-            logger.info("rc_entry: " + rc_entry[0])
             rcs = rc_entry[0].split('\n')
             alt = addEditorAlternatives(rcs)
             alt_rc_entry.insert(0, alt)
         elif len(rc_entry) > 1:
-            logger.info("rc_entry: " + rc_entry[idx])
             rcs = rc_entry[idx].split('\n')
             alt = addEditorAlternatives(rcs)
             alt_rc_entry.insert(idx, alt)
@@ -818,7 +816,7 @@ def checkOtherEntries():
     checkProgAlternatives('available index processors', ['texindy', 'makeindex -c -q'],
         rc_entry = [ r'\index_command "%%"' ],
         alt_rc_entry = [ r'\index_alternatives "%%"' ])
-    checkProg('an index processor appropriate to Japanese', ['mendex -c -q', 'makeindex -c -q'],
+    checkProg('an index processor appropriate to Japanese', ['mendex -c -q', 'jmakeindex -c -q', 'makeindex -c -q'],
         rc_entry = [ r'\jindex_command "%%"' ])
     path, splitindex = checkProg('the splitindex processor', ['splitindex.pl', 'splitindex'],
         rc_entry = [ r'\splitindex_command "%%"' ])