delorie.com/archives/browse.cgi   search  
Mail Archives: geda-help/2013/01/12/14:22:14

X-Authentication-Warning: delorie.com: mail set sender to geda-help-bounces using -f
X-Recipient: geda-help AT delorie DOT com
X-Cam-AntiVirus: no malware found
X-Cam-SpamDetails: not scanned
X-Cam-ScannerInfo: http://www.ucs.cam.ac.uk/email/scanner/
Message-ID: <1358018496.2901.3.camel@localhost>
Subject: Re: [geda-help] export PCB silkscreen without refdes names
From: Peter Clifton <pcjc2 AT cam DOT ac DOT uk>
To: geda-help AT delorie DOT com
Date: Sat, 12 Jan 2013 19:21:36 +0000
In-Reply-To: <CAP3H+HY-84+svKxei4q9GDy4eEVwsJZrwV2eZJ_Dcm6JqDeY9A@mail.gmail.com>
References:
<CAP3H+HY8K8aXYdua-QF=hRC5LQ3-KQa1FqH24jkthLTwhLwBwA AT mail DOT gmail DOT com>
<201301112120 DOT r0BLKLla029311 AT envy DOT delorie DOT com>
<CAP3H+HY-84+svKxei4q9GDy4eEVwsJZrwV2eZJ_Dcm6JqDeY9A AT mail DOT gmail DOT com>
X-Mailer: Evolution 3.6.2-0ubuntu2
Mime-Version: 1.0
Reply-To: geda-help AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: geda-help AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

On Sat, 2013-01-12 at 01:15 +0200, Duncan Drennan wrote:
> > The easiest (only?) way is to hack the sources.  Look in src/draw.c
> > starting with DrawEverything()
> 
> I see that DrawElementName checks the HIDENAMESFLAG, but
> DrawEverything() uses the DrawLayer() function to draw the top and
> bottom silk layers for exporting.
> 
> I guess one way would be to check the layer name and the HIDENAMESFLAG
> and then skip this step in DrawLayer()

You could hide the name on every element on the board (I think the
keyboard short-cut is "h"), or: apply something like the following
patch. It may not apply cleanly, as it is from a personal stack of
commits on the top of my OpenGL branches.

I have needed this before myself, as typically - on boards where I'm not
going to have a silk-screen produced, I won't go to the effort of moving
every silk annotation into the correct place.


commit 9db0771b89bf5bc854dd0ecada544502e4e88517
Author: Peter Clifton <pcjc2 AT cam DOT ac DOT uk>
Date:   Thu Nov 15 01:46:48 2012 +0000

    Comment out check for GUI HID when considering hidenames
    
    Yes - I want to hide them for a print!

diff --git a/src/draw.c b/src/draw.c
index 96e2473..8f91ba6 100644
--- a/src/draw.c
+++ b/src/draw.c
@@ -184,7 +184,7 @@ void ghid_set_lock_effects (hidGC gc, AnyObjectType *object);
 static void
 draw_element_name (ElementType *element)
 {
-  if ((TEST_FLAG (HIDENAMESFLAG, PCB) && gui->gui) ||
+  if ((TEST_FLAG (HIDENAMESFLAG, PCB) /*&& gui->gui*/) ||
       TEST_FLAG (HIDENAMEFLAG, element))
     return;
   ghid_set_lock_effects (Output.fgGC, (AnyObjectType *)element);




> /* draw the layer text on screen */
>   r_search (Layer->text_tree, screen, NULL, text_callback, Layer);
> 
> but that doesn't seem very elegant....too much of a special case in a
> generic function.

-- 
Peter Clifton <peter DOT clifton AT clifton-electronics DOT co DOT uk>

Clifton Electronics

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019