src/Tools/jEdit/src/jedit/ProverSetup.scala
changeset 34440 561a6d19bd95
parent 34438 2faedc70b52d
child 34441 ff3b7ae2b12a
equal deleted inserted replaced
34439:7df6275c4b3f 34440:561a6d19bd95
    38   }
    38   }
    39 
    39 
    40   val output_text_view = new JTextArea("== Isabelle output ==\n")
    40   val output_text_view = new JTextArea("== Isabelle output ==\n")
    41   
    41   
    42   def activate(view : View) {
    42   def activate(view : View) {
    43     val logic = Plugin.property("logic")
    43     val logic = Isabelle.property("logic")
    44     prover.start(if (logic == null) logic else "HOL")
    44     prover.start(if (logic == null) logic else "HOL")  // FIXME avoid hardwired logic
    45     val buffer = view.getBuffer
    45     val buffer = view.getBuffer
    46     val dir = buffer.getDirectory()
    46     val dir = buffer.getDirectory()
    47 
    47 
    48     theory_view = new TheoryView(view.getTextArea)
    48     theory_view = new TheoryView(view.getTextArea)
    49     prover.setDocument(theory_view ,
    49     prover.setDocument(theory_view ,
    50                        if (dir.startsWith(Plugin.VFS_PREFIX)) dir.substring(Plugin.VFS_PREFIX.length) else dir)
    50                        if (dir.startsWith(Isabelle.VFS_PREFIX)) dir.substring(Isabelle.VFS_PREFIX.length) else dir)
    51     theory_view.activate
    51     theory_view.activate
    52     prover.outputInfo.add( text => {
    52     prover.outputInfo.add( text => {
    53         output_text_view.append(text)
    53         output_text_view.append(text)
    54         val dockable = view.getDockableWindowManager.getDockable("isabelle-output")
    54         val dockable = view.getDockableWindowManager.getDockable("isabelle-output")
    55         //link process output if dockable is active
    55         //link process output if dockable is active
    76     })
    76     })
    77  
    77  
    78     //register for theory-view
    78     //register for theory-view
    79 
    79 
    80     // could also use this:
    80     // could also use this:
    81     // prover.commandInfo.add(c => Plugin.theory_view.repaint(c.command))
    81     // prover.commandInfo.add(c => Isabelle.theory_view.repaint(c.command))
    82 
    82 
    83   }
    83   }
    84 
    84 
    85   def deactivate {
    85   def deactivate {
    86     //TODO: clean up!
    86     //TODO: clean up!