*** /home/marc/latex.lang	2017-04-09 12:57:11.000000000 +0200
--- /usr/share/gtksourceview-3.0/language-specs/latex.lang	2017-04-28 12:48:17.970449165 +0200
***************
*** 47,52 ****
--- 47,53 ----
      <style id="subsubsection"      _name="SubSubSection Heading" map-to="def:heading4"/>
      <style id="paragraph"          _name="Paragraph Heading"     map-to="def:heading5"/>
      <style id="subparagraph"       _name="SubParagraph Heading"  map-to="def:heading6"/>
+     <style id="url"                _name="URL"                   map-to="def:underlined"/>
    </styles>
  
    <definitions>
***************
*** 107,112 ****
--- 108,158 ----
        </include>
      </context>
  
+     <!-- 
+         Examples: \url{http://google.de}, \href{http://google.de}{Google} 
+ 
+         Supports also urls with math symbols: \url{https://zoidberg.ukp.informatik.tu-darmstadt.de/jenkins/job/DKPro\%20Core\%20Documentation\%20(GitHub)/de.tudarmstadt.ukp.dkpro.core$de.tudarmstadt.ukp.dkpro.core.doc-asl/doclinks/1/user-guide.html}
+     -->
+     <context id="urls">
+       <include>
+         <context ref="url-command"/>
+         <context ref="href-command"/>
+       </include>
+     </context>
+ 
+     <context id="url-command">
+       <match extended="true">
+         (\\url)            # url command.
+         \{                 # Literal opening braces.
+           [ \t]*           # Optional spaces or tabs after the opening braces.
+           (.*?)            # URL 
+           [ \t]*           # Optional spaces or tabs before the closing braces.
+         \}                 # closing url command.
+       </match>
+ 
+       <include>
+         <context sub-pattern="1" class="no-spell-check" style-ref="command"/>
+         <context sub-pattern="2" class="no-spell-check" style-ref="url"/>
+       </include>
+     </context>
+ 
+     <context id="href-command">
+       <match extended="true">
+         (\\href)           # url command.
+         \{                 # Literal opening braces.
+           [ \t]*           # Optional spaces or tabs after the opening braces.
+           (.*?)            # URL 
+           [ \t]*           # Optional spaces or tabs before the closing braces.
+         \}                 # closing url command.
+         \{(.*?)\}          # link text
+       </match>
+ 
+       <include>
+         <context sub-pattern="1" class="no-spell-check" style-ref="command"/>
+         <context sub-pattern="2" class="no-spell-check" style-ref="url"/>
+       </include>
+     </context>
+ 
      <!--using brackets is an experimental feature from the listings package. The
          following must support these cases:
  
***************
*** 582,587 ****
--- 628,634 ----
          <context ref="R-block"/>
          <context ref="headings"/>
          <context ref="math"/>
+         <context ref="urls"/>
          <context ref="specific-commands"/>
          <context ref="common-commands"/>
          <context ref="special-char"/>
