--- a/src/Pure/General/long_name.scala Sat Apr 08 12:31:29 2017 +0200
+++ b/src/Pure/General/long_name.scala Sat Apr 08 12:47:34 2017 +0200
@@ -21,6 +21,10 @@
if (qual == "" || name == "") name
else qual + separator + name
+ def qualifier(name: String): String =
+ if (name == "") ""
+ else implode(explode(name).dropRight(1))
+
def base_name(name: String): String =
if (name == "") ""
else explode(name).last
--- a/src/Pure/PIDE/document.scala Sat Apr 08 12:31:29 2017 +0200
+++ b/src/Pure/PIDE/document.scala Sat Apr 08 12:47:34 2017 +0200
@@ -117,6 +117,7 @@
def loaded_theory: Name = Name(theory, "", theory)
def is_theory: Boolean = theory.nonEmpty
+ def theory_qualifier: String = Long_Name.qualifier(theory)
def theory_base_name: String = Long_Name.base_name(theory)
override def toString: String = if (is_theory) theory else node