Results 1 to 20 of 216

Thread: QCodeEdit

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Jan 2006
    Location
    travelling
    Posts
    1,116
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows
    Thanks
    8
    Thanked 127 Times in 121 Posts

    Default Re: QCodeEdit

    Quote Originally Posted by NoobSaibot View Post
    btw. do you have a issue tracker?
    As QCodeEdit is developed as part of Edyuk you should use Edyuk issue tracker on Sf.net or the WebIssues server (http://edyuk.org/webissues/ login : anonymous, pwd : anonymous)
    Current Qt projects : QCodeEdit, RotiDeCode

  2. #2
    Join Date
    Jan 2008
    Posts
    22
    Qt products
    Qt4
    Platforms
    Unix/X11
    Thanks
    3

    Default Re: QCodeEdit

    some minor bug in the column selection:

    - start column selection in the first column down to the last line of the file
    - now hold shift and try to select the text to the right with the arrow key

    the result is that all but the last cursor mirrors do what they should. the last -- down most -- cursor mirror does not move along with the others.

  3. #3
    Join Date
    Jan 2008
    Posts
    22
    Qt products
    Qt4
    Platforms
    Unix/X11
    Thanks
    3

    Default Re: QCodeEdit

    well, you gonna hate me aswell , however,

    is it possible to enter column selection mode without the mouse?

  4. #4
    Join Date
    Jan 2006
    Location
    travelling
    Posts
    1,116
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows
    Thanks
    8
    Thanked 127 Times in 121 Posts

    Default Re: QCodeEdit

    Quote Originally Posted by NoobSaibot View Post
    some minor bug in the column selection:

    - start column selection in the first column down to the last line of the file
    - now hold shift and try to select the text to the right with the arrow key

    the result is that all but the last cursor mirrors do what they should. the last -- down most -- cursor mirror does not move along with the others.
    I'm afraid I haven't been able to reproduce this one.Check that you are using last rev. Try rebuilding QCodeEdit (make clean) and send me the files with which it happens in case the problem remains.

    is it possible to enter column selection mode without the mouse?
    It wasn't but it now is. The new binding is : CTRL + ALT + up/down to add a new mirror above the first/under the last cursor mirror.
    Current Qt projects : QCodeEdit, RotiDeCode

  5. The following user says thank you to fullmetalcoder for this useful post:

    NoobSaibot (18th January 2008)

  6. #5
    Join Date
    Jan 2008
    Posts
    22
    Qt products
    Qt4
    Platforms
    Unix/X11
    Thanks
    3

    Default Re: QCodeEdit

    thanks a bunch! i'll recompile and attach the files to the bug report. if you care, i modified qdocument.cpp a little bit, as i find this folding rect ugly as hell (i borrowed some images from textmate)

    /edit: well actually there's nothing to attach to the bug report, as it happens right on the start; there's no file loaded at all. hmmm, might be my system configuration.
    Attached Images Attached Images
    Last edited by NoobSaibot; 18th January 2008 at 22:28. Reason: updated contents

  7. #6
    Join Date
    Jan 2006
    Location
    travelling
    Posts
    1,116
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows
    Thanks
    8
    Thanked 127 Times in 121 Posts

    Default Re: QCodeEdit

    Quote Originally Posted by NoobSaibot View Post
    if you care, i modified qdocument.cpp a little bit, as i find this folding rect ugly as hell (i borrowed some images from textmate)
    AFAIK, and I should know quite welll , the drawing of folding rects isn't done in qdocument.cpp but in qfoldpanel.cpp
    Anyway, I think I should add a way to change the look of fold indicators.

    Quote Originally Posted by NoobSaibot View Post
    /edit: well actually there's nothing to attach to the bug report, as it happens right on the start; there's no file loaded at all. hmmm, might be my system configuration.
    This is only a small drawing bug which appears on empty lines in some case. Well, appeared actually for I just fixed it.
    Current Qt projects : QCodeEdit, RotiDeCode

  8. #7
    Join Date
    Jan 2008
    Posts
    22
    Qt products
    Qt4
    Platforms
    Unix/X11
    Thanks
    3

    Default Re: QCodeEdit

    Quote Originally Posted by fullmetalcoder View Post
    AFAIK, and I should know quite welll , the drawing of folding rects isn't done in qdocument.cpp but in qfoldpanel.cpp
    Anyway, I think I should add a way to change the look of fold indicators.
    nahh, i mean the dotted rectangle in the text document which appears when you activate the folding. and yes, the +/- rectangles are drawn in the foldpanel -- i wrote my own fold panel ( which is actually a copy of your qfoldpanel with minor modifications ).

    thanks for fixing!! continue the great work.

    if you could provide me the information where i get the current syntax used. i don't seem to be able to figure that one out

  9. #8
    Join Date
    Jan 2006
    Location
    travelling
    Posts
    1,116
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows
    Thanks
    8
    Thanked 127 Times in 121 Posts

    Default Re: QCodeEdit

    Quote Originally Posted by NoobSaibot View Post
    nahh, i mean the dotted rectangle in the text document which appears when you activate the folding.
    OK. Did you replace it with something nicer or just removed it?

    Quote Originally Posted by NoobSaibot View Post
    and yes, the +/- rectangles are drawn in the foldpanel -- i wrote my own fold panel ( which is actually a copy of your qfoldpanel with minor modifications ).
    Are you using images or hardcoded drawing code? Maybe we could make this configurable and keep a single fold panel class...

    Quote Originally Posted by NoobSaibot View Post
    if you could provide me the information where i get the current syntax used. i don't seem to be able to figure that one out
    The current design makes this a bit tricky... I got plans to improve this but I'd like to make this version as stable as possible before making API changes... Anyway you should be able to get this information using something like :
    Qt Code:
    1. editor->highlighter()->definition()->language();
    To copy to clipboard, switch view to plain text mode 
    where "editor" is a QEditor*
    This will give you the language used as a QString as it appears in the qnfa file.
    note : you'd better check for the existence of an highlighter before proceeding, unless you forced one to be set on all your editors...
    Current Qt projects : QCodeEdit, RotiDeCode

  10. The following user says thank you to fullmetalcoder for this useful post:

    NoobSaibot (19th January 2008)

  11. #9
    Join Date
    Jan 2008
    Posts
    22
    Qt products
    Qt4
    Platforms
    Unix/X11
    Thanks
    3

    Default Re: QCodeEdit

    Quote Originally Posted by fullmetalcoder View Post
    OK. Did you replace it with something nicer or just removed it?
    you didn't see the attached images i posted? i replaced the dotted lines with an image, which is placed right after the last nonspace character.

    it'd be wonderful if there'd be a way to define own theme! it ain't that urgent though snippets are my #1 feature request. did you take a look at textmate manual/screencasts?

    /edit: wonderful, now i know which highlighter is used

  12. #10
    Join Date
    Jan 2008
    Posts
    22
    Qt products
    Qt4
    Platforms
    Unix/X11
    Thanks
    3

    Default Re: QCodeEdit

    if you consider to make qcodeedit themable, consider the following:

    for constructions like imbedded php/ruby/java in html it should be possible to define the background color for such areas. thus -- generally speaking -- something like that should be possible:
    <background ... image="" color="" id="text.html code.java" />

    might be hard to implement , but as you love challenges there you go!
    Last edited by NoobSaibot; 19th January 2008 at 12:43.

  13. #11
    Join Date
    Jan 2006
    Location
    travelling
    Posts
    1,116
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows
    Thanks
    8
    Thanked 127 Times in 121 Posts

    Default Re: QCodeEdit

    Quote Originally Posted by NoobSaibot View Post
    you didn't see the attached images i posted? i replaced the dotted lines with an image, which is placed right after the last nonspace character.
    I didn't pay attention to this... The first time I viewed your attachement I only noticed the new icons in the panel.

    Quote Originally Posted by NoobSaibot View Post
    snippets are my #1 feature request. did you take a look at textmate manual/screencasts?
    I gave it a quick look but din't started writing anything... As I said already I have very little time and I'm currently focusing on bugfixing/polishing to make this version stable. As soon as I'll reach this state and have more spare time I'll start playing around with new stuff, including snippets, but this day has not come yet...

    Quote Originally Posted by NoobSaibot View Post
    /edit: wonderful, now i know which highlighter is used
    Good. Just curious : what do you do with this information? You display some additional text in a status panel or something like that?

    Quote Originally Posted by NoobSaibot View Post
    for constructions like imbedded php/ruby/java in html it should be possible to define the background color for such areas. thus -- generally speaking -- something like that should be possible:
    <background ... image="" color="" id="text.html code.java" />

    might be hard to implement , but as you love challenges there you go
    The use of a background color isn't difficult in itself... The only challenge is in finding the right paradigm to make this configurable... I'll think about it.
    Current Qt projects : QCodeEdit, RotiDeCode

  14. #12
    Join Date
    Jan 2008
    Posts
    22
    Qt products
    Qt4
    Platforms
    Unix/X11
    Thanks
    3

    Default Re: QCodeEdit

    Quote Originally Posted by fullmetalcoder View Post
    Good. Just curious : what do you do with this information? You display some additional text in a status panel or something like that?
    i plan to have a dropdown in status panel, where i/the user can switch between the languages.

    Quote Originally Posted by fullmetalcoder View Post
    The use of a background color isn't difficult in itself... The only challenge is in finding the right paradigm to make this configurable... I'll think about it.
    well, again. textmate is *the* reference. take a language bundle ( c/c++ for instance ) and look at the files and the structure used there.

  15. #13
    Join Date
    Jan 2006
    Location
    travelling
    Posts
    1,116
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows
    Thanks
    8
    Thanked 127 Times in 121 Posts

    Default Re: QCodeEdit

    Quote Originally Posted by NoobSaibot View Post
    well, again. textmate is *the* reference. take a language bundle ( c/c++ for instance ) and look at the files and the structure used there.
    Well, I was considering the internal design, not user-configuration side...
    Current Qt projects : QCodeEdit, RotiDeCode

  16. #14
    Join Date
    Jan 2008
    Posts
    22
    Qt products
    Qt4
    Platforms
    Unix/X11
    Thanks
    3

    Default Re: QCodeEdit

    in order to provide the information about the current highlighter, i added a signal to QEditor::setHighlighter(), highlighterChanged(). consider to make that change in your trunk.

    you fixed missing lines? :thumbs up: i encountered some file corruptions as i was using edyuk. some lines got swollowed. is that what you've fixed?

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.