Can I disable the "pushed" effect of a button???

I heared I need to extend Button and override paint(),
but how do I override paint() only to disable the "pushed" effect?

Heres an example of how I paint sunken, raised and etched panels.
public void paint(Graphics g)
          switch(DrawObject)
               case SUNKEN: drawSunkenPanel(g); break;
               case RAISED: drawRaisedPanel(g); break;
               case ETCHED: drawEtchedPanel(g); break;
               default: return;
     public void drawSunkenPanel(Graphics g)
          g.setColor(java.awt.Color.darkGray);
               //inner left hand side
               g.drawLine( (getInsets().left + 1), getInsets().top, (getInsets().left + 1), (getBounds().height - 2) );
               //inner top
               g.drawLine(getInsets().left, (getInsets().top + 1), (getBounds().width - 2), (getInsets().top + 1) );
          g.setColor(java.awt.Color.gray);
               //far left hand side
               g.drawLine(getInsets().left, getInsets().top, getInsets().left, (getBounds().height - 1) );
               //far top          
               g.drawLine(getInsets().left, getInsets().top, (getBounds().width - 1), getInsets().top);
          g.setColor(java.awt.Color.white);
               //far right side
               g.drawLine(     (getBounds().width - 1), 0, (getBounds().width - 1), getBounds().height);
               //far bottom
               g.drawLine(getInsets().left, (getBounds().height - 1), getBounds().width, (getBounds().height - 1) );
          g.setColor(java.awt.Color.lightGray);
               //far right side
               g.drawLine(     (getBounds().width - 2), 1, (getBounds().width - 2), (getBounds().height - 2) );
               //far bottom
               g.drawLine( (getInsets().left + 1), (getBounds().height - 2), (getBounds().width - 2), (getBounds().height - 2) );
     public void drawRaisedPanel(Graphics g)
          g.setColor(java.awt.Color.white);
          g.drawLine(getInsets().left, getInsets().top, getInsets().left, getBounds().height);
          g.drawLine(getInsets().left, getInsets().top, getBounds().width, getInsets().top);
          g.setColor(java.awt.Color.gray);
          g.drawLine(     (getBounds().width - 1), 0, (getBounds().width - 1), getBounds().height);
          g.drawLine(getInsets().left, (getBounds().height - 1), getBounds().width, (getBounds().height - 1) );
     public void drawEtchedPanel(Graphics g)
          g.setColor(java.awt.Color.darkGray);
          int w = getBounds().width - 1; // these are points
          int h = getBounds().height - 1;
          //White lines
          g.setColor(java.awt.Color.white);
               //North side     
               g.drawLine( 1, 1, w, 1);
               //East Side
               g.drawLine( w, 1, w, h);
               //South
               g.drawLine( 1, h, w, h);
               //West
               g.drawLine( 1, 1, 1, h);
          //Gray Lines
          g.setColor(java.awt.Color.gray);
               //North
               g.drawLine( 0, 0, w-1, 0 );
               //East
               g.drawLine( w-1, 0, w-1, h-1);
               //South
               g.drawLine( 0, h-1, w-1, h-1 );
               //west
               g.drawLine( 0, 0, 0, h-1);
     }

Similar Messages

  • Can you disable the bounce effect while scrolling?

    Whenever you scroll in applications like Safari and Mail and you reach the 'border' of the application, you get a little bounce effect like in iOS. I find this to be very annoying and I was wondering if there was a way to turn this off.

    Why?... is there any point??? I thought I liked it for about 15 seconds and then it started to feel like a joke... now it just feels a bit like last year's favorite shirt.

  • Can we disable the default push buttons on the ALV Grid

    Hi,
        Can we disable the default push buttons on the ALV
    Grid Control...
        If so, pls send me the procedure...
    thanks and regards
       raghu

    Hi,
    In the PBO:
      PERFORM f9100_exclude_functions USING :
                             i_exclude[]  '&CHECK',
                             i_exclude[]  '&REFRESH',
                             i_exclude[]  '&LOCAL&CUT' ,
                             i_exclude[]  '&LOCAL&COPY',
                             i_exclude[]  '&LOCAL&PASTE',
                             i_exclude[]  '&LOCAL&PASTE_NEW_ROW',
                             i_exclude[]  '&LOCAL&UNDO' ,
                             i_exclude[]  '&LOCAL&APPEND',
                             i_exclude[]  '&LOCAL&INSERT_ROW',
                             i_exclude[]  '&LOCAL&DELETE_ROW',
                             i_exclude[]  '&SORT_ASC',
                             i_exclude[]  '&SORT_DSC',
                             i_exclude[]  '&FIND',
                             i_exclude[]  '&SUMC',
                             i_exclude[]  '&SUBTOT',
                             i_exclude[]  '&MINIMUM',
                             i_exclude[]  '&MAXIMUM' ,
                             i_exclude[]  '&VGRID' ,
                             i_exclude[]  '&VEXCEL' ,
                             i_exclude[]  '&VCRYSTAL',
                             i_exclude[]  '&HTML',
                             i_exclude[]  '&MAINTAIN',
                             i_exclude[]  '&SAVE',
                             i_exclude[]  '&GRAPH',
                             i_exclude[]  '&HELP',
                             i_exclude[]  '&ALL' ,
                             i_exclude[]  '&SAL' .
    *                         i_exclude[]  '&EXCLALLFC'.
    *&      Form  f9100_exclude_functions
    * This form exclude buttons  from the toolbar.
    *      -->P_IEXCLUDE  text
    *      -->P_1150   text
    FORM f9100_exclude_functions USING   pexclude LIKE i_exclude
                                   value(pfunction).
      DATA: l_exclude TYPE ui_func.
      l_exclude = pfunction.
      APPEND l_exclude TO pexclude.
    ENDFORM.                    " f9100_exclude_functions
    This will exculde the default push buttons.
    Let us know if it works for you.
    Regards,
    Anjali

  • How can I disable the shift-click slow motion special effects in Mac OS 10.6?

    How can I disable the slow motion special effects that occur when you do something and hold shift? (By the way, the terminal command doesn't work in 10.6)

    I'd like to know how to do this now too since the terminal command doesn't work in Lion / ML. Anyone know how?
    And Leroy - the reason is because I have custom hot keys configured and the shift key is a key I want to use for this command. I would like to know how to disable the slow motion effect permanently since I never need it and would certainly like to use my shift key as a modifier for various keyboard commands.

  • I have ios 7.1.2 and I still can't find a way to completely disable the parallax effect but keep animations

    I understand that reduce motion disables the parallax effect but it also disables the animations. When I turn perspective zoom off, it keeps the background from moving when I tilt my iPhone but the apps still movie. How do I make the background and the apps stay still but keep the animations? Is there even a way to do that?

    In technical support, sometimes you have to make educated guesses. I'm sorry that you were offended.
    iTunes does prompt when it is going to erase a device, and the message is clear.
    She said in her message that she was able to successfully sync the old ipad. This indicated to me that itunes wiping the data was not an issue, because either it had been setup at the apple store (in which case it doesn't actually wipe the ipad despite saying it will*) (*based on a single case I saw), or because the itunes media folder was migrated.
    Furthermore, my solution was to tell her how to backup her ipad (by either doing it manually, or as a last resort, by deleting the corrupt backup -- that she couldn't access anyway.)
    I got that last part of the instructions from the "Taking Control of your iphone" book which I found samples of when I did a google search for "corrupted backup itunes".
    She marked this as a solution, so it worked for her.

  • I have purchased a macbook air with 64 gb hard disk. the available space is only 10gb. With this available space, i can't use the system effectively. kindly advise.

    I have purchased a macbook air with 64 gb hard disk. the available space is only 10gb. With this available space, i can't use the system effectively. kindly advise.

    You should have bought one with a larger SSD. You can regain some space by disabling the sleepimage file:
    To disable safe sleep, run the two following commands in Terminal:
    $ sudo pmset -a hibernatemode 0
    $ sudo nvram "use-nvramrc?"=false
    When done, restart your computer. Now go delete the file "/private/var/vm/sleepimage" to free up some hard drive space. When you put your computer to sleep it, should happen in under five seconds; my MacBook now goes to sleep in two seconds.
    [robg adds: To state the obvious, with safe sleep disabled, a total power loss will wipe out whatever was open on your machine. To enable safe sleep mode again, repeat the above commands, but change hibernatemode 0 on the first line to hibernatemode 3, and =false to =true on the second line. You'll then need to reboot again. Personally, I prefer the safe sleep mode, even with the slower sleep time and hard drive consumption -- even if for no other reason than it's great when changing batteries on a flight.]
    You can also delete unneeded files:
    Freeing Up Space on The Hard Drive
      1. See Lion/Mountain Lion's Storage Display.
      2. You can remove data from your Home folder except for the /Home/Library/ folder.
      3. Visit The XLab FAQs and read the FAQ on freeing up space on your hard drive.
      4. Also see Freeing space on your Mac OS X startup disk.
      5. See Where did my Disk Space go?.
      6. See The Storage Display.
    You must Empty the Trash in order to recover the space they occupied on the hard drive.
    You should consider replacing the drive with a larger one. Check out OWC for drives, tutorials, and toolkits.
    Try using OmniDiskSweeper 1.8 or GrandPerspective to search your drive for large files and where they are located.

  • How do I disable the cube effect when switching between accounts?

    Hello, I have a friend who wants to turn off the animated cube effect that happens when they switch between theirs and their wife's accounts. After a lot of googling I am not having much luck finding out how to do it. Does anyone here know?
    Interestingly, you can see what a difference it makes by loading "Quartz Debug" and unchecking "Enable Quartz Extreme" - makes fast user switching really fast! But I don't want to permanently disable Quartz Extreme, I just want to turn off this one animation.

    You can't disable the animation, as it is a part of the system/account controller as far as I know.

  • Can I disable the audio pitch adjustment when using frame rate conversion?

    We have a mov file containing digitized film material with audio scanned at 25 fps (1 frame film for 1 frame video) while the film should be 18 fps.
    So both video and audio are too fast.
    Compressor provides the framerate conversion so source plays at x frames per second.
    This works well for video but the audio slowed down remains the pitch it has in the original speed. A great feature but an unwanted result in this case.
    Audio should be at a lower pitch since it was recorded too fast.
    Can we disable the pitch adjustment, when using rate conversion, so the pitch is corrected (lower) as well?

    Hi Jason
    This does sound tricky - the only other suggestion that I can add to David's is to use the smallest GOP setting you can, I'm in PAL land so the default is 12frames but I push it down to 7, this forces more I-frames into your mpeg. It makes the file size higher but in a project your length it doesn't matter. Make sure you encode your audio to .ac3 (use the Dolby 2.0 preset in compressor). Although David's limit is 7.4, if I'm not playing back on a laptop I'll set my CBR to 8Mbps (in Compressor CBR is called 'one-pass').
    Once you create your mpeg, play it back in Quicktime first to make sure there are no artifacts full screen (with Simulators reduced size sometimes artifacts exist in your orig mpeg that you may not notice).
    Also as David said, DVDSP doesn't re-encode an existing mpeg so something else must be going on. Before you re-import your new mpeg, delete your DVDSP prefs and any menu mpegs that it has created.
    If you have Toast, try just doing a Build, instead of Build & Format. This will give a VIDEO_TS folder that you can then burn in Toast. Use the Data tab and select DVD-ROM/UDF.
    If this doesn't work I don't know what will.
    Good luck!
    B

  • Can I disable the alert "the referenced account is currently locked out..."

    I posted the following on the answers site but was recommended to post here
    http://answers.microsoft.com/en-us/windows/forum/windows_7-security/can-i-disable-the-alert-the-referenced-account-is/0af4441c-2f70-4452-a876-7c582fbd6530
    A client has asked me to enable an account lockout threshold on their domain.
    I have made the appropriate changes in Group Policy and also configured an email notification under Task Scheduler that is triggered by Event ID 4740 appearing in the security log. http://community.spiceworks.com/scripts/show/1588-send-email-on-account-lock-out
    It was when testing this that I noted after the nth incorrect password, I received an on screen alert "the referenced account is currently locked out and cannot be logged on to"
    I tested again with an invalid username and did not get the same message. This is potentially a problem because it means that an attacker sees a difference between a valid username and an invalid username without being required to know any correct
    passwords.
    Is there any way that I can disable this on screen alert so that attackers are not presented with a means to validate usernames?
    I am already aware that account lockouts are no longer in favour for other reasons and have informed the client about the possibility of a denial of service attack that deliberately triggers these lockouts and taken certain steps to mitigate the
    effects.
    However, given that an informed decision has been made to stick with the account lockout policy I would like to be able to mitigate this other undesired consequence if at all possible.

    Hi Matt,
    I understand your concern, although I wasn’t able to find a way to disable or change these embedded Windows messages.
    With Account Lockout policy enabled, the risk that accounts being hacked has been reduced a lot. In addition, we can monitor security logs to determine whether hacking behaviors exist or not.
    More information for you:
    Audit Policy Recommendations
    http://technet.microsoft.com/en-us/library/dn487457.aspx
    Configuring Audit Policies
    http://technet.microsoft.com/en-us/library/dd277403.aspx
    Best Regards,
    Amy

  • How can I disable the Voicemail button on an iPhone 4

    How can I disable the Voicemail button on an iPhone 4 or
    if that is not possible can i programme it to dial my own phone rather than my carrier's Voicemail box?

    No, it's not possible to disable that button and no, it's not possible to reprogram it to anything else.

  • How can I DISABLE the pop up 'Would you like to copy it to Library', preventing this message from bothering for each and every book, again and again, time after time? (Windows 7 64bit US).

    How can I DISABLE the pop up 'Would you like to copy it to Library', preventing this message from bothering for each and every book, again and again , time after time? (Windows 7 64bit US).
    I guess this may be a feature request. Adobe may think this is a good message for every new eBook.
    I sure would like to decide about that myself.
    Thanks in advance if this will be changed.

    singmk wrote:
    Decided to setup the mail for exchange on my N8 so I could see my work emails. Worked like a charm but after a couple of hours decided I didn't like being that contactable so deleted the mailbox.
    Now to the problem, during setup I was forced to enable the phone lock and had to pick a 7 digit alphanumeric code. Fair enough I thought and went ahead. When I removed the mailbox however the lock remained in place with the default auto time of 30 minutes. When I checked in Phone management there is no option to disable this lock so I thought I could at least change the default time to something bigger but when you try, it remains at 30 mins. You also can't disable the auto time as it pops up an error message saying can't unlock phone.
    Does anyone know if I'm missing something obvious here or is this something which can't be disabled once it's switched on? I've done a soft reset back to factory settings with no luck and the only other thing I can think of is re installing the firmware which seems a bit extreme.
    Would like to hope there is some way to have control over this. Can someone help?
    Which firmware your N8 having now? You can check firmware by choosing Call, then type *#0000#.
    My N8 works fine on security setting and able to define Phone auto lock period, by choosing Menu>Settings>Phone>Phone management>Security settings>Phone and SIM card>Phone auto lock period>User defined>Lock after(minutes)
    You will prompt to enter Lock code each time u define auto lock priod or enable/disable auto lock.
    Hope this can help you.
    If you find this post helpful, please show your appreciation by clicking the Kudos star at the left. If it provides you the solution, please click on the GREEN Accept as Solution button at below

  • How can i disable the credit card from that stolen acc and register to my new account

    Hello everywone i have a big problem.. Somewone stole my apple id and changed everything (email , secret question). In that account was my credit card registered. how can i disable the credit card from that stolen acc and register to my new account ?? thanks for help

    Is it an IMAP or POP account?
    For POP accounts, you can select remove from server under the advanced tab of the account.
    Apple support article with information on receiving a message more than once:
    Mail Problems

  • How can I disable the automatic hiding of known file attachments, and why are always about 10 internet pages where I have to download something if i use firefo

    How can I disable the automatic hiding of known file attachments, and why are always about 10 internet pages where I have to download something when I use mozila firefox?
    Windows Computer

    1) If you are talking about the file names on the computer, there is a
    setting to turn off known file types. Open your file browser. Then
    just under the location bar, press '''Tools,''' then '''Folder Options.'''
    A new window will open. Select '''View.''' Look for
    '''Hide Extensions For Known File Types.'''
    2) Never NEVER '''NEVER''' download anything unless you know what
    it is. If a web site claims it needs to download something, what is it?
    It could be something like the flash player, '''or a virus ! !'''
    Ask questions, or go somewhere else.

  • How can I disable the behance pics during the startup of my CC 2014 programmes?

    When I start my photoshop cc 2014 and illustrator and all other apps, there ware always some behance pics from users.
    is there a way to disable them?
    thanks a lot
    alex

    hi sarah,
    thanks for getting back to me.
    i mean these images:
    when the programmes are starting up…
    thanks a lot for your help
    alex
    Am 08.01.2015 um 16:05 schrieb SarahBehance1 <[email protected]>:
    How can I disable the behance pics during the startup of my CC 2014 programmes?
    created by SarahBehance1 in Behance - View the full discussion
    HI Alex - can you send a screenshot of what you're seeing? I'm not sure what you're referring to.
    Talk to you soon, thanks!
    If the reply above answers your question, please take a moment to mark this answer as correct by visiting: https://forums.adobe.com/message/7077548#7077548 and clicking ‘Correct’ below the answer
    Replies to this message go to everyone subscribed to this thread, not directly to the person who posted the message. To post a reply, either reply to this email or visit the message page:
    Please note that the Adobe Forums do not accept email attachments. If you want to embed an image in your message please visit the thread in the forum and click the camera icon: https://forums.adobe.com/message/7077548#7077548
    To unsubscribe from this thread, please visit the message page at , click "Following" at the top right, & "Stop Following"
    Start a new discussion in Behance by email or at Adobe Community
    For more information about maintaining your forum email notifications please go to https://forums.adobe.com/thread/1516624.
    Alex an der Haas
    Art Direction
    // Die Goldkinder
    // Ausdenken und Machen.
    // Mollardgasse 85A / Stiege 3 / Top 142, 1060 Wien
    // Tel: +43 (0) 1 595.37.07
    // Mob: +43 (0) 699.816.366.31
    // http://www.diegoldkinder.at

  • How can I disable the light of my keyborad?

    Hello everybody!!! I wonder how can I disable the light from my keyboard. I just can change the colors in 4 differents ways but none of then can switch off the light of my keyboard. I have a GT70 2PC. Thanks for your time .

    you should be able to turn off and on with FN and + to turn on then FN and the - button i think it was to turn off the backlight it's on number pad area to the right you should see light form icon showing light is on and then another 1 that is showing it's off
    here is pic of marked buttons that i'm talking about.

Maybe you are looking for

  • Free Transform breaks Motion Tweens

    Sigh! Normally I try to solve problems myself... but Google isn't giving me anything about this so maybe I'm the only one in the world experiencing this particular issue. I've used Flash for making games for years now, and I got used to using the old

  • Workflow Tasks NOT expiring!

    Hi guys, I've bumped lately with an issue building a workflow on SP2010, as you mostly already have figured out from the title, workflow tasks are NOT expiring. I've tried to take this on my own, but no more as I have to move on. Here's the details;

  • Error message in ical

    When I try to utilize iCalendar I get this error message: Authentication of account "marilyn's calendar" failed. Please check your login and password information. Any ideas what to do about this? Thanks, Marilyn

  • ISE 1.2 / WLC 5508 EAP-TLS expired certificate error, but wireless still working

    Hi I have a customer that we've deployed ISE 1.2 and WLC 5508s at.  Customer is using EAP-TLS with and everything appears to setup properly.  Users are able to login to the network and authenticate, however, frequently, I'm getting the following erro

  • Safari 5.1.7 crashes on win7

    regular crashes, when running multiple tabs, safari.exe and webkit2webprocess.exe occupying HUGE amount of memory (e.g. 200.000 to 800.000K)