Re: DateLayer Problems

From: Don Dietrick <dietrick@bbn.com>
Date: Fri Jul 19 2002 - 12:24:42 EDT

Hi Stephanie,

There was a problem with the OMText background color problems, and they
have been fixed for the next release due out very shortly (4.5.1).

Cheers,

Don

On Monday, July 15, 2002, at 03:20 PM, Stephanie Piet wrote:

> Hi Everyone,
>  
> I've been recently working on a layer that extends off of
> DateLayer.java. What I'm trying to do is change the foreground and
> background colors once the DateLayer is turned on. I've created a GUI
> in which you can select which colors you want for the
> background/foreground. Now the code for the foreground color works just
> fine, but I seem to be having trouble with the background color and
> getting it to draw on the map. Here's some of the code below. I'm
> fairly new to OpenMap/Java, I would appreciate any input/suggestions.
>  
> /********************************************************************//
> //**** Set up color chooser for setting Background color ****//
> //******************************************************************//
>              bcc.addActionListener(
>                  new ActionListener() {
>                      public void actionPerformed(ActionEvent e) {
>                          Color newColor = JColorChooser.showDialog(
>                                                      RPMDateLayer.this,
>                                                     "Choose Background
> Color",
>                                                     
> sample.getBackground());
>  
>                         if (newColor != null) {
>                              sample.setBackground(newColor);
>  
>         /**Implements the Background Color**/
>  
>                              bgColor = newColor;
>                              setLabelText(sample.getText());
>                              text.setShowBounds(true);
>                              text.setBoundsLineColor(bgColor);
>                              text.setBoundsFillColor(bgColor);
>                             text.generate(getProjection());
>                              repaint();
>                                             }
>                                     }
>                              });
>  
>
> /*******************************************************************//
> //**** Set up color chooser for setting Foreground color ****//
> //*****************************************************************//
>  
>              bcc1.addActionListener(
>                  new ActionListener()
>                  {
>                      public void actionPerformed(ActionEvent e)
>                      {
>                          Color newColor = JColorChooser.showDialog(
>                                                      RPMDateLayer.this,
>                                                      "Choose Foreground
> Color",
>                                                     
> sample.getForeground());
>  
>                          if (newColor != null)
>                          {
>                              sample.setForeground(newColor);
>  
>  
>                             /**Implements the Foreground Color**/
>  
>                              fgColor = newColor;
>                              text.setLinePaint(fgColor);
>                          }
>                       }
>                   });
>  
>  
>  
>  
>  
>  
> Thanks!
>  
>  
>  
>  
>  
> **********************
> Stephanie K. Piet
> OptiMetrics, Inc.
> 2107 Laurel Bush Rd. Suite 209
> Bel Air, MD 21015
> SPiet@OptiMetrics.org
> http://www.OptiMetrics.org
> (410)569-6081 ext: 111
> fax: (410)569-6083
>

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Don Dietrick, BBN Technologies, dietrick@bbn.com
10 Moulton Street, Cambridge, MA 02138
617-873-3031 [fax]-2794
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

--
[To unsubscribe to this list send an email to "majdart@bbn.com"
with the following text in the BODY of the message "unsubscribe openmap-users"]
Received on Fri Jul 19 12:26:25 2002

This archive was generated by hypermail 2.1.8 : Thu May 12 2005 - 07:18:33 EDT