* * *

Author Topic: Problem Switching Code Editor to Form Editor  (Read 1591 times)

garlar27

  • Sr. Member
  • ****
  • Posts: 488
Problem Switching Code Editor to Form Editor
« on: March 29, 2017, 06:53:35 pm »
Hello,

   I'm having problems to switch from Code Editor to Form Editor (if form editor is closed). It just don't works whether I use F12 key Toolbar button or main menu.

Is there any thing I can do to make it work again?

I tried deleting the project session file (.lps) but it didn't worked.

I'm using Lazarus 1.6.2

knuckles

  • Jr. Member
  • **
  • Posts: 93
Re: Problem Switching Code Editor to Form Editor
« Reply #1 on: April 01, 2017, 12:42:44 am »
What OS are you using?

Thaddy

  • Hero Member
  • *****
  • Posts: 4413
Re: Problem Switching Code Editor to Form Editor
« Reply #2 on: April 01, 2017, 02:20:27 pm »
Maybe F12 is taken by the OS.
You can change the Key via Tools|Options|KeyMapping (search for F12) into a different key or key combination.
« Last Edit: April 01, 2017, 02:30:33 pm by Thaddy »
"Logically, no number of positive outcomes at the level of experimental testing can confirm a scientific theory, but a single counterexample is logically decisive."

garlar27

  • Sr. Member
  • ****
  • Posts: 488
Re: Problem Switching Code Editor to Form Editor
« Reply #3 on: April 03, 2017, 04:38:35 pm »
I'm Using Windows 10.

I know the key is not taken by de OS because some times it works.

The problem is with some old projects. Now my main suspect is the SVN, since I'm using 1.6.x and the rest is using an old 1.1 (I'm "upgrading" the projects to work smoothly with the new version since we were working with a pretty old version of everything  :-[ :-X ).
I need to check the .lfm files to see if there is something wrong on them but I don't know where to find info on the .lfm (and .lpi just in case) changes...
 :-[

molly

  • Hero Member
  • *****
  • Posts: 1790
Re: Problem Switching Code Editor to Form Editor
« Reply #4 on: April 03, 2017, 04:55:32 pm »
@garlar27:
does it also fail when trying to press F12 twice (or sometimes even thrice) ? e.g. that is the situation i often find myself doing.

garlar27

  • Sr. Member
  • ****
  • Posts: 488
Re: Problem Switching Code Editor to Form Editor
« Reply #5 on: April 03, 2017, 05:57:44 pm »
@molly:
It doesn't matter how many times I press F12 key it is like I haven't done anything.

Out of topic:
In older Lazarus versions some times the F12 key wouldn't bring up the right form (don't remember if the 1.6.x has the same issue).

Thaddy

  • Hero Member
  • *****
  • Posts: 4413
Re: Problem Switching Code Editor to Form Editor
« Reply #6 on: April 03, 2017, 06:15:00 pm »
Is the correct keyboard driver  installed? E.g. a keyboard with extended keys? If that is wrong you will run into this issue because the last one is by default F10 That's on Linux and Windows.... But it should not happen...Unless you ordered the OS to do so...
"Logically, no number of positive outcomes at the level of experimental testing can confirm a scientific theory, but a single counterexample is logically decisive."

garlar27

  • Sr. Member
  • ****
  • Posts: 488
Re: Problem Switching Code Editor to Form Editor
« Reply #7 on: April 04, 2017, 02:48:52 pm »
Is the correct keyboard driver  installed? E.g. a keyboard with extended keys? If that is wrong you will run into this issue because the last one is by default F10 That's on Linux and Windows.... But it should not happen...Unless you ordered the OS to do so...

Well, at least Firefox recognizes the F11 and F12. And Lazarus does it too. But in some projects after closing the Form Editor, and pressing the F12 key (nor pressing the "Switch Form/Unit View" neither using de menu "View/Switch Form/Unit View") while in the form's unit tab the Form Editor won't come back up.

eny

  • Hero Member
  • *****
  • Posts: 1561
Re: Problem Switching Code Editor to Form Editor
« Reply #8 on: April 04, 2017, 09:55:26 pm »
Yeah I recognize the problem.
Sometimes it helps pressing F11 (switch to object inspector) and then F12.
All posts based on: Win10 (Win64); Lazarus 1.4.2 'stable' (#49524 win32) unless specified otherwise...

garlar27

  • Sr. Member
  • ****
  • Posts: 488
Re: Problem Switching Code Editor to Form Editor
« Reply #9 on: April 04, 2017, 10:02:47 pm »
Yeah I recognize the problem.
Sometimes it helps pressing F11 (switch to object inspector) and then F12.
I've also tried that. But since there is no control selected in the Object Inspector I cant bring back the form Editor....
I'm starting to think in installing Sparta but I don't want to stop using AnchorDockingDsgn.

molly

  • Hero Member
  • *****
  • Posts: 1790
Re: Problem Switching Code Editor to Form Editor
« Reply #10 on: April 04, 2017, 10:20:27 pm »
Yeah I recognize the problem.
Sometimes it helps pressing F11 (switch to object inspector) and then F12.
I am able to confirm on that. sometimes that helps.

I've come so accustomed to it that whenever my workbench is empty, i'm pressing these f11/f12 combination a couple of times without giving it any thought.


I'm a bit bit puzzled by garlar27's experience, as was stated that sometimes it works, while  other times (particular projects?) not at all.

As far as i am able to remember, i've only experienced this twice or thrice, and for such cases, closing down lazarus, starting it again and loading the project 'fixed' that for me.
« Last Edit: April 04, 2017, 10:34:24 pm by molly »

Cyrax

  • Hero Member
  • *****
  • Posts: 535
Re: Problem Switching Code Editor to Form Editor
« Reply #11 on: April 05, 2017, 01:52:55 pm »
See this link: http://muzso.hu/2011/12/13/setting-f12-as-a-global-hotkey-in-windows

Excerpt from the link:
Quote
The F12 key is reserved for use by the debugger at all times, so it should not be registered as a hot key. Even when you are not debugging an application, F12 is reserved in case a kernel-mode debugger or a just-in-time debugger is resident.

 

Recent

Get Lazarus at SourceForge.net. Fast, secure and Free Open Source software downloads Open Hub project report for Lazarus