Qt Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Unsolved

    Shortcuts not working QtCreator 2.6.2

    Tools
    1
    1
    1147
    Loading More Posts
    • 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.
    • M
      Mevos last edited by

      Hello everyone,

      First time poster here...

      I'm currently developing using Qt 5.0.1 on Ubuntu 12.10 with a French Canadian keyboard layout and some of my shortcuts in QtCreator are not working. The most important shortcut being the one to comment and uncomment code. I should note that the standard shortcut requires me to press an additional shift key modifier and that I've had this problem in the past with older versions of Qt on Windows 7 with less critical shortcuts.

      On top of that when I try to make shortcuts in Qml, as an example, I can't use the normal Qt.Key_Enter, I have to use a String comparison where "16777220" corresponds to the normal Qt.Key_Enter. But most keys that I tried seemed to be working properly.

      I also tried to create the equivalent of my comment command in Qml using the following, which did work. Which means they are likely to be two different issues.
      @
      Item {
      focus:true
      Keys.onPressed: {
      if(event.modifiers && Qt.ControlModifier) {
      if(event.key === Qt.Key_Slash) { // works!
      console.log('Ctrl + Shift + 3! my "Ctrl + /"');
      event.accepted = true;
      }
      }
      if(event.key === Qt.Key_Enter) { // Does not work!
      console.log('Enter!');
      event.accepted = true;
      }

          }
      

      }
      @

      As I am not sure if it's an issue on my side or a bug on Qt's side, I figured it would just be better to ask a question about it to sort it out.

      Mevos

      1 Reply Last reply Reply Quote 0
      • First post
        Last post