Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Behind the Scenes
  3. Wiki Discussion
  4. Use "standard" {{{ and }}} delimiters for code sections
Forum Updated to NodeBB v4.3 + New Features

Use "standard" {{{ and }}} delimiters for code sections

Scheduled Pinned Locked Moved Wiki Discussion
10 Posts 5 Posters 4.5k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • T Offline
    T Offline
    techtonik
    wrote on last edited by
    #1

    It would be really convenient if code sections could be inserted into {{{ and }}} tags. These are less common than @@ inside source files and won't cause issues like http://developer.qt.nokia.com/forums/viewthread/1059/

    The {{{ and }}} convention is used by Trac, Google Code and MoinMoin wiki.

    1 Reply Last reply
    0
    • G Offline
      G Offline
      goetz
      wrote on last edited by
      #2

      Good idea. Jira/Confluence uses {{xx}} for inline code and {code}abc{code} for blocks (i.e. it always starts on a new line).

      http://www.catb.org/~esr/faqs/smart-questions.html

      1 Reply Last reply
      0
      • D Offline
        D Offline
        dangelog
        wrote on last edited by
        #3

        I agree, and I'd also like to see the ability to specify the source language (C++ / QML / JS / Python / Perl / SH / unformatted / ...) in order to get proper syntax highlighting.

        Software Engineer
        KDAB (UK) Ltd., a KDAB Group company

        1 Reply Last reply
        0
        • T Offline
          T Offline
          techtonik
          wrote on last edited by
          #4

          Here is the description of how to specify language in Trac - http://trac.edgewall.org/wiki/WikiProcessors#CodeHighlightingSupport

          What language/license is used for this Wiki? Will it be possible to use Trac processor together with pygments for code highlighting?

          1 Reply Last reply
          0
          • V Offline
            V Offline
            vsorokin
            wrote on last edited by
            #5

            Now used "Textile":http://warpedvisions.org/projects/textile-cheat-sheet/ markup language, I don't see sense for change part of it.

            --
            Vasiliy

            1 Reply Last reply
            0
            • T Offline
              T Offline
              techtonik
              wrote on last edited by
              #6

              It doesn't seem like Textile is appropriate choice for code development communities.

              1 Reply Last reply
              0
              • V Offline
                V Offline
                vsorokin
                wrote on last edited by
                #7

                Why not? Textile is easy and convenient. And Editor have visual button is on panel. What's the difference what would be the tag?

                --
                Vasiliy

                1 Reply Last reply
                0
                • S Offline
                  S Offline
                  stukdev
                  wrote on last edited by
                  #8

                  Exactly what is the sense of change the tag? Maybe is a good improve the markup syntax.
                  Vut if the cose is '@'code'@' or {{{code}}} or [coder]code[/coder] don't change anything.

                  1 Reply Last reply
                  0
                  • D Offline
                    D Offline
                    dangelog
                    wrote on last edited by
                    #9

                    Because '@' is more likely to be found inside a source code or in other text than }}}, thus it easily screws up formatting:

                    @
                    QString email(QLatin1String("foo@ bar.com"));
                    @

                    (the above thing is broken intentionally). I'm not saying we should remove at, but simply ADD the other ones (and, for instance, leave ATs for inline code and [ code ] [ / code ] for blocks).

                    And still, how about supporting more than one language (namely, C++)? [ code lang = perl ] [ / code ] would make it easy.

                    --

                    To say it all, I'm hating textile. It's really fragile and really unfit for a IT / Tech forum.

                    Software Engineer
                    KDAB (UK) Ltd., a KDAB Group company

                    1 Reply Last reply
                    0
                    • T Offline
                      T Offline
                      techtonik
                      wrote on last edited by
                      #10

                      Most people are not familiar with Textile, and new people find its syntax rather weird. Thanks to PySide bindings you may expect many Python users who are used to Trac, Moinmoin and reStructuredText, but not to Textile. The [code] and @@ conventions are clumsy.

                      1 Reply Last reply
                      0

                      • Login

                      • Login or register to search.
                      • First post
                        Last post
                      0
                      • Categories
                      • Recent
                      • Tags
                      • Popular
                      • Users
                      • Groups
                      • Search
                      • Get Qt Extensions
                      • Unsolved