Author Topic: Compile error symbol in gutter is missing  (Read 2558 times)

Magnus

  • Community Member
  • Posts: 5
  • Hero Points: 0
Compile error symbol in gutter is missing
« on: January 26, 2007, 03:37:14 pm »
I have configured SlickEdit to use our compiler and also configured error parsing to be able to jump from the error messages to the line in code, but I the red symbol in the gutter indicating error is now missing, how can I bring it back is it some configuration?
/Magnus

Lee

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 1067
  • Hero Points: 90
Re: Compile error symbol in gutter is missing
« Reply #1 on: January 26, 2007, 03:54:11 pm »
Are you using Project > Build command using your own command line or are you using a user created project tool from Project Properties?  The automated error markers are only keyed off from Project > Build, Rebuild and Compile tools.  There are other settings which are required to get the error markers to appear.  The "Capture output" and "Output to build window" options are may also be required as well.  The command-line you specify is required to be passed through to our "vsbuild" utility for the error marker processing to work, and I believe using those options will use vsbuild.  Check all these options and see if their set, if your still having issues, I may need to take a look at your project file (or a simple example project) to see what's going on.

hs2

  • Senior Community Member
  • Posts: 2727
  • Hero Points: 281
Re: Compile error symbol in gutter is missing
« Reply #2 on: January 28, 2007, 01:56:06 pm »
If you want to run your own 'build-tool' incl. error markers etc. and you need some add. macro support.
The build_magnus macro just manually calls execute_post_build, which should do the job.
Optionally you could add your own post build callback actions.
Example:
- goto the 1st error found
- if no error detected: make a 'noisy' jump to the bottom of the build window and re-activate edit win
Code: [Select]
_command void bottom_of_build() name_info(',')
{
   int formwid = activate_toolbar("_tbshell_form", "_shellEditor");
   if (!formwid) return;

   _nocheck _control _shellEditor;
   int wid = formwid._shellEditor;
   activate_window ( wid );
   bottom();
}

void _postbuild_magnus (...)
{
   // say ("proj_name:" arg( 1 ) );
   if ( next_error () )
   {
      bottom_of_build ( );
      cursor_data();
      _beep ();
   }
}

_command void build_magnus ( _str buildtoolname='' ) name_info (','VSARG2_READ_ONLY|VSARG2_REQUIRES_EDITORCTL)
{
   if ( buildtoolname != '' )
   {
      activate_build ();
      reset_next_error();

      // uncomment if needed
      // clear_all_error_markers();

      project_build ( buildtoolname );
      execute_post_build (_project_name);  // calls set_error_markers() internally
   }
   else
   {
      message ( "buildtoolname missing." );
   }
}

With that you can specify a 'Magnus' build command (and much more) and run it e.g on cmdline:
build-magnus Magnus

Of course you have to take care about the capture setup Lee mentioned above.

Hope it helps,

HS2

Magnus

  • Community Member
  • Posts: 5
  • Hero Points: 0
Re: Compile error symbol in gutter is missing
« Reply #3 on: January 29, 2007, 11:59:17 am »
Thank you for all your help, but I have not managed to see the compiler gutter symbols unless I run the execute_post_build after a compilation.

I uses the project properties to set up compile, and all the boxes are checked.
Have also tried to add a _postbuild_cmd() but it is only called when I run the execute_post_build as well.