Search Results

Search found 8498 results on 340 pages for 'integrated graphics'.

Page 88/340 | < Previous Page | 84 85 86 87 88 89 90 91 92 93 94 95  | Next Page >

  • How to encode(represent) an ornament?

    - by Daniyar
    I would like to find a numeric representation of kazakh national ornaments for generating new ones. The ornaments essentially consist of combinations of relatively basic ornaments. Usually the ornaments are symmetrical. Here are few examples of basic elements: (The images are a bit distorted) And this is an example of a more complex ornament: How could I encode an ornament's representation in as few numbers as possible? So that I could write a program that would generate an ornament, given some sequence of numbers Any ideas are appreciated. As I write this, I have thought that generating images of snowlfakes may be somewhat relevant, although it's possibly just a fractal.

    Read the article

  • Converting between square and rectangular pixel co-ordinates

    - by FlyboyUtah
    I'm new at using transforms and this type of math, and would appreciate some direction solving my coding problem. I'm writing in XCode for the iphone, and am working with CGraphics. Problem: In Xcode, I want to draw curves, lines and so on it's screen of of square pixels. Then convert those points, as close as possible, into non-square pixel sysem. For example if the original coordinate system is 500 x 500 pixels that are displayed on square screen of 10 by 10 inchs I draw a round circle with the circle formula. It looks round, and all is well. Now, I draw the same circle on a second 10 x 10 inch screen that is 850 pixels by 500 pixels. Without changing the coordinates, the same circle formual displays something that looks like an egg. How can I draw the circle on the second screen in a different coordinate system? And in addition, I need to access the set of points x,y system individually. s

    Read the article

  • Canvas draw calls are rendering out of sequence

    - by Tom Murray
    I have the following code for writing draw calls to a "back buffer" canvas, then placing those in a main canvas using drawImage. This is for optimization purposes and to ensure all images get placed in sequence. Before placing the buffer canvas on top of the main one, I'm using fillRect to create a dark-blue background on the main canvas. However, the blue background is rendering after the sprites. This is unexpected, as I am making its fillRect call first. Here is my code: render: function() { this.buffer.clearRect(0,0,this.w,this.h); this.context.fillStyle = "#000044"; this.context.fillRect(0,0,this.w,this.h); for (var i in this.renderQueue) { for (var ii = 0; ii < this.renderQueue[i].length; ii++) { sprite = this.renderQueue[i][ii]; // Draw it! this.buffer.fillStyle = "green"; this.buffer.fillRect(sprite.x, sprite.y, sprite.w, sprite.h); } } this.context.drawImage(this.bufferCanvas,0,0); } This also happens when I use fillRect on the buffer canvas, instead of the main one. Changing the globalCompositeOperation between 'source-over' and 'destination-over' (for both contexts) does nothing to change this. Paradoxically, if I instead place the blue fillRect inside the nested for loops with the other draw calls, it works as expected... Thanks in advance!

    Read the article

  • Drag & Drop Shapes on Canvas

    - by user242408
    Hi, I put several shapes (like Ellipse and Rectangle) on a Canvas. Now, I want user to be able to drag & drop these shapes. Is there some predefined functionality that I can use, or I should implement the drag & drop myself using the mouse events ? Thanks !

    Read the article

  • How to take a layer's snapshot with mask layer?

    - by OpenThread
    I added a mask to UIView's layer: CGImageRef maskImageRef = [UIImage imageNamed:"Icon.png"].CGImage; CALayer maskLayer = [CALayer layer]; maskLayer.contents = (__bridge id)maskImageRef; self.layer.mask = maskLayer; Then I use this code to get snapshot from a UIView: [self.layer renderInContext:mainViewContentContext]; But the mask wasn't drawn. How to draw self.layer with mask? Special thx!

    Read the article

  • HTML/CSS Design for Report

    - by Kevin Brown
    I'm looking for some resources that demonstrate good graphic design for generated (PHP/HTML/CSS) reports. The website I'm designing is essentially a long test. Everything is finished except the report generation, and this part needs to look good! I'd appreciate any advice/resources you can point me to! I know this isn't directly programming related, but my purposes do encompass coding and output.

    Read the article

  • how to create a plot with customized points in R?

    - by kloop
    I know I can create a plot with line and dots using the type = "o" argument in the plot command. I would like some more control over this -- I want to be able to draw the "o" as full dots, with black border and fill-in color of my choice, of customized size and of a different color than the line. Same for the line, I want to make it thicker, and of my choice of color. How would I go on about doing that? What I found until now is just a plain plot(y, type= "o") which is too poor for my needs. I am not interested in using ggplot, but instead use the internal plot library of R. Any help appreciated.

    Read the article

  • when is the right time to draw

    - by stupid_idiot
    hi i just finished essential part of my own personal 2d engine in c++ and i'm kinda deciding how to complete the part where it is actually supposed to display everything on the screen, namely when do I call that function which does the job. I don't have much idea of how does the graphic card work, my biggest experience is calling bios graphic services to write some stuff on the screen. Could you give me a hint on this pls? Or maybe some keywords I should try to google?

    Read the article

  • How to use integrated support for dyndns clients in 2Wire router ?

    - by Frank
    I logged into the 2Wire web interface, and get to "Broadband Link Advanced Settings" page, how do I use it's integrated support for dyndns clients ? Under "Broadband DNS" it has "Obtain DNS information automatically" selected, under that : Manually configure your DNS information: Primary Server: Secondary Server: Domain Name: what do I need to do ?

    Read the article

  • g++ linker error--typeinfo, but not vtable

    - by James
    I know the standard answer for a linker error about missing typeinfo usually also involves vtable and some virtual function that I forgot to actually define. I'm fairly certain that's not the situation this time. Here's the error: UI.o: In function boost::shared_ptr<Graphics::Widgets::WidgetSet>::shared_ptr<Graphics::Resource::GroupByState>(boost::shared_ptr<Graphics::Resource::GroupByState> const&, boost::detail::dynamic_cast_tag)': UI.cpp:(.text._ZN5boost10shared_ptrIN8Graphics7Widgets9WidgetSetEEC1INS1_8Resource12GroupByStateEEERKNS0_IT_EENS_6detail16dynamic_cast_tagE[boost::shared_ptr<Graphics::Widgets::WidgetSet>::shared_ptr<Graphics::Resource::GroupByState>(boost::shared_ptr<Graphics::Resource::GroupByState> const&, boost::detail::dynamic_cast_tag)]+0x30): undefined reference totypeinfo for Graphics::Widgets::WidgetSet' Running c++filt on the obnoxious mangled name shows that it actually is looking at .boost::shared_ptr::shared_ptr(boost::shared_ptr const&, boost::detail::dynamic_cast_tag) The inheritance hierarchy looks something like class AbstractGroup { typedef boost::shared_ptr<AbstractGroup> Ptr; ... }; class WidgetSet : public AbstractGroup { typedef boost::shared_ptr<WidgetSet> Ptr; ... }; class GroupByState : public AbstractGroup { ... }; Then there's this: class UI : public GroupByState { ... void LoadWidgets( GroupByState::Ptr resource ); }; Then the original implementation: void UI::LoadWidgets( GroupByState::Ptr resource ) { WidgetSet::Ptr tmp( boost::dynamic_pointer_cast< WidgetSet >(resource) ); if( tmp ) { ... } } Stupid error on my part (trying to cast to a sibling class with a shared parent), even if the error is kind of cryptic. Changing to this: void UI::LoadWidgets( AbstractGroup::Ptr resource ) { WidgetSet::Ptr tmp( boost::dynamic_pointer_cast< WidgetSet >(resource) ); if( tmp ) { ... } } (which I'm fairly sure is what I actually meant to be doing) left me with a very similar error: UI.o: In function boost::shared_ptr<Graphics::Widgets::WidgetSet>::shared_ptr<Graphics::_Drawer::Group>(boost::shared_ptr<Graphics::_Drawer::Group> const&, boost::detail::dynamic_cast_tag)': UI.cpp:(.text._ZN5boost10shared_ptrIN8Graphics7Widgets9WidgetSetEEC1INS1_7_Drawer5GroupEEERKNS0_IT_EENS_6detail16dynamic_cast_tagE[boost::shared_ptr<Graphics::Widgets::WidgetSet>::shared_ptr<Graphics::_Drawer::Group>(boost::shared_ptr<Graphics::_Drawer::Group> const&, boost::detail::dynamic_cast_tag)]+0x30): undefined reference totypeinfo for Graphics::Widgets::WidgetSet' collect2: ld returned 1 exit status dynamic_cast_tag is just an empty struct in boost/shared_ptr.hpp. It's just a guess that boost might have anything at all to do with the error. Passing in a WidgetSet::Ptr totally eliminates the need for a cast, and it builds fine (which is why I think there's more going on than the standard answer for this question). Obviously, I'm trimming away a lot of details that might be important. My next step is to cut it down to the smallest example that fails to build, but I figured I'd try the lazy way out and take a stab on here first. TIA!

    Read the article

  • xorg, nvidia, log-in all hosed - how can I completely reset graphics set-up/settings?

    - by Fred Hamilton
    I just did a fresh install of Mythbuntu 12.04.1 on my Intel MB with nVidia 9500GT graphics card. Hardware's been working great with 10.10 for about 2 years. Background: (optional - feel free to skip to question) I was trying to get my component video output to generate 720p, messing around with the nvidia drivers, and now the entire display system is hosed. I can SSH in and get a terminal. Depending on which nvidia package I install/remove, I get: Garbage on screen (after I "apt-get remove nvidia*") A low-res graphical log-in screen where I can log in as fred or guest. If I log in as fred, it displays some text mode status line then goes right back to the log-in screen. If I log in as guest, I actually get the full Ubuntu desktop, but I need to be able to log in as fred. Other times I get an error: "API mismatch: the NVIDIA kernel module has version 304.43, but this NVIDIA driver component has version 295.49." I've googled around, including trying this thread with the same error message, but to no effect. Question: How can I just reset x settings, drivers, everything display-related to the exact same way it was after a fresh install?

    Read the article

  • I have problem on 12.10 64bit with nvidia graphics driver opensource and proprietary ! Can't change resolution on 3d games

    - by digitalcrow
    I have problem with nvidia graphics driver opensource and proprietary ! Can't change resolution on 3d games and there's a bug there are no kernel sources installed and thus jockey can't install proprietary drivers. I can't change resolution while on games fullscreen. I tried to install proprietary driver and i couldn't plus i couldn't login to ubuntu it showed only the desktop photo no dash no nothing. -tried to install kernel sources and blacklist+remove Nouveau drivers and then installed the proprietary drivers i hope succesfully. -The problem is the same i can't change resolution on 3d games while on fullscreen. I've installed the sources and be able to install the proprietary nvidia drivers but the problem remains, look what i got in the output of a 3d game exited while i tried to change resolution: X Error of failed request: BadValue (integer parameter out of range for operation) Major opcode of failed request: 150 (XFree86-VidModeExtension) Minor opcode of failed request: 10 (XF86VidModeSwitchToMode) Value in failed request: 0x25b Serial number of failed request: 497 Current serial number in output stream: 499 I'm giving you more details about my system: i have an nvidia geforce gts 250 , 3,4 ghz quadcore amd phenom2 , 8gbytes of ram. The output of: sudo lshw -C display; lsb_release -a; uname -a Is the following: *-display description: VGA compatible controller product: G92 [GeForce GTS 250] vendor: NVIDIA Corporation physical id: 0 bus info: pci@0000:01:00.0 version: a2 width: 64 bits clock: 33MHz capabilities: pm msi pciexpress vga_controller bus_master cap_list rom configuration: driver=nvidia latency=0 resources: irq:18 memory:fa000000-faffffff memory:d0000000-dfffffff memory:f8000000-f9ffffff ioport:ef00(size=128) memory:fb000000-fb01ffff No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 12.10 Release: 12.10 Codename: quantal Linux darkpc 3.5.0-17-generic #28-Ubuntu SMP Tue Oct 9 19:31:23 UTC 2012 x86_64 x86_64 x86_64 GNU/Linux I like ubuntu's style and user interface but i hate the bad quality of work they do.

    Read the article

  • How do I solve "System is running in low graphics issue" in Ubuntu INSTALLER ?

    - by hellodear
    I made a bootable USB for installing Ubuntu 12.04 LTS alongside Windows 8.1. I inserted my USB device and then booted into it. Then it showed me 2 options - 'Try Ubuntu' or 'Install Ubuntu'. Now I press 'Try Ubuntu' and then it says, "The system is running in low graphics mode". Then I press 'OK'. Then it showed me 4 options. Then again I click 'OK'. Then it shows a black screen and nothing happens. I have tried all possible answers provided in AU. What should I do? Please help. PS :- I am using Windows 8.1 with dedicated graphic card which is AMD Radeon HD 8670M. I am trying to do this in a Dell Laptop 3537 Inspiron. UPDATE :- I tried running the liveUSB session with nomodeset on and i was able to enter the installer. But when I run boot-repair(so that my Ubuntu gets detected in the GRUB menu) after installing Ubuntu successfully alongside Windows 8(following this tutorial with nomodeset on, I get the following error:- your system is running in legacy mode boot repair done

    Read the article

  • Why is Mac supposedly better than Windows for graphics?

    - by Svish
    Ok, people just keep telling me that if you're going to be working with graphics and design and stuff, you should get a Mac. And I just don't get the logic. Because most of these people would be working with Adobe software, which are for both Windows and Mac. To me it seems like their whole argument is based on that "everyone else does". Like, Mac had some graphics software that Windows didn't earlier in history, so most people were using Mac. And since most people were using Mac, new people also started using Mac. And since most people were using Mac, schools and universities used Mac. Which taught new people to use Mac. So they were using Mac. And told everyone they met that everyone they knew were using Mac. And so on. Anyways... What is the deal really? Is there actually any advantage in using Mac for graphics and design and such things? My take is that you pretty much have the same software and both Mac and Windows are powerful enough, support enough RAM, are stable (as long as you don't install lot's of junk or faulty drivers), et cetera. So, can anyone give me a good explanation on this? Is there a real difference or are people just brainwashed?

    Read the article

  • How can something relevant to graphics completely kill a motherboard?

    - by leladax
    I was coding something in OpenGL and after a bug there was an 'OS slowed down' situation. After a few seconds the screen went blank and the laptop shutdown. Now not even a led turns on battery or not. It doesn't appear to be the AC or the battery since there was some battery when it died and when it's connected to the AC the laptop produces near the AC connection a very slight 'clicking' noise (very faint, one has to be very careful to notice it, I don't know if it was there forever tbh). I suspect the motherboard died, as in something from the point it gets AC or battery power and the point it actually feeds itself. But I can't figure out how that effect was produced by the OpenGL bug or graphics overheating. If the graphics died alone, it should at least give some indication that the laptop is barely alive, at least a led, a sound, anything, the laptop is instead completely dead (other than faint 'clicking' I mentioned). Does anyone have expert advice on this? I'm especially interested in any ideas connected to "graphics overheated/bugged ---- they killed motherboard". I have a very lengthy experience in that stuff as a hobbyist and it really puzzles me. It's not just a "AC died" situation I can easily google.

    Read the article

  • Sprite batching in OpenGL

    - by Roy T.
    I've got a JAVA based game with an OpenGL rendering front that is drawing a large amount of sprites every frame (during testing it peaked at 700). Now this game is completely unoptimized. There is no spatial partitioning (so a sprite is drawn even if it isn't on screen) and every sprite is drawn separately like this: graphics.glPushMatrix(); { graphics.glTranslated(x, y, 0.0); graphics.glRotated(degrees, 0, 0, 1); graphics.glBegin(GL2.GL_QUADS); graphics.glTexCoord2f (1.0f, 0.0f); graphics.glVertex2d(half_size , half_size); // upper right // same for upper left, lower left, lower right graphics.glEnd(); } graphics.glPopMatrix(); Currently the game is running at +-25FPS and is CPU bound. I would like to improve performance by adding spatial partitioning (which I know how to do) and sprite batching. Not drawing sprites that aren't on screen will help a lot, however since players can zoom out it won't help enough, hence the need for batching. However sprite batching in OpenGL is a bit of mystery to me. I usually work with XNA where a few classes to do this are built in. But in OpenGL I don't know what to do. As for further optimization, the game I'm working on as a few interesting characteristics. A lot of sprites have the same texture and all the sprites are square. Maybe these characteristics will help determine an efficient batching technique?

    Read the article

  • Wireless internet is connected to an open network but has no internet

    - by Joshua Reeder
    I just installed Ubuntu on my laptop yesterday and it connected to the wireless fine. Then I took it to school, put it on their wired connection, downloaded some stuff, and now the wireless doesn't work. At first it would detect networks, but not connect. I restarted it and now it can connect, but it acts like it doesn't have internet in the browser. Wired connection still works fine on it. I know it isn't the network because my ipad is working on the wireless connection fine. I found another solution on here switching the security settings for the wireless, but this is the apartment's wireless so they have it open, and I won't be able to mess with it at all. Here is lspci output: 00:00.0 Host bridge: Intel Corporation Core Processor DMI (rev 11) 00:03.0 PCI bridge: Intel Corporation Core Processor PCI Express Root Port 1 (rev 11) 00:08.0 System peripheral: Intel Corporation Core Processor System Management Registers (rev 11) 00:08.1 System peripheral: Intel Corporation Core Processor Semaphore and Scratchpad Registers (rev 11) 00:08.2 System peripheral: Intel Corporation Core Processor System Control and Status Registers (rev 11) 00:08.3 System peripheral: Intel Corporation Core Processor Miscellaneous Registers (rev 11) 00:10.0 System peripheral: Intel Corporation Core Processor QPI Link (rev 11) 00:10.1 System peripheral: Intel Corporation Core Processor QPI Routing and Protocol Registers (rev 11) 00:16.0 Communication controller: Intel Corporation 5 Series/3400 Series Chipset HECI Controller (rev 06) 00:1a.0 USB controller: Intel Corporation 5 Series/3400 Series Chipset USB2 Enhanced Host Controller (rev 05) 00:1b.0 Audio device: Intel Corporation 5 Series/3400 Series Chipset High Definition Audio (rev 05) 00:1c.0 PCI bridge: Intel Corporation 5 Series/3400 Series Chipset PCI Express Root Port 1 (rev 05) 00:1c.1 PCI bridge: Intel Corporation 5 Series/3400 Series Chipset PCI Express Root Port 2 (rev 05) 00:1c.2 PCI bridge: Intel Corporation 5 Series/3400 Series Chipset PCI Express Root Port 3 (rev 05) 00:1c.3 PCI bridge: Intel Corporation 5 Series/3400 Series Chipset PCI Express Root Port 4 (rev 05) 00:1c.4 PCI bridge: Intel Corporation 5 Series/3400 Series Chipset PCI Express Root Port 5 (rev 05) 00:1d.0 USB controller: Intel Corporation 5 Series/3400 Series Chipset USB2 Enhanced Host Controller (rev 05) 00:1e.0 PCI bridge: Intel Corporation 82801 Mobile PCI Bridge (rev a5) 00:1f.0 ISA bridge: Intel Corporation Mobile 5 Series Chipset LPC Interface Controller (rev 05) 00:1f.2 SATA controller: Intel Corporation 5 Series/3400 Series Chipset 4 port SATA AHCI Controller (rev 05) 00:1f.3 SMBus: Intel Corporation 5 Series/3400 Series Chipset SMBus Controller (rev 05) 01:00.0 VGA compatible controller: NVIDIA Corporation GT218 [GeForce 310M] (rev a2) 01:00.1 Audio device: NVIDIA Corporation High Definition Audio Controller (rev a1) 02:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8101E/RTL8102E PCI Express Fast Ethernet controller (rev 05) 07:00.0 Network controller: Realtek Semiconductor Co., Ltd. RTL8191SEvB Wireless LAN Controller (rev 10) 16:00.0 System peripheral: JMicron Technology Corp. SD/MMC Host Controller (rev 20) 16:00.2 SD Host controller: JMicron Technology Corp. Standard SD Host Controller (rev 20) 16:00.3 System peripheral: JMicron Technology Corp. MS Host Controller (rev 20) 16:00.4 System peripheral: JMicron Technology Corp. xD Host Controller (rev 20) ff:00.0 Host bridge: Intel Corporation Core Processor QuickPath Architecture Generic Non-Core Registers (rev 04) ff:00.1 Host bridge: Intel Corporation Core Processor QuickPath Architecture System Address Decoder (rev 04) ff:02.0 Host bridge: Intel Corporation Core Processor QPI Link 0 (rev 04) ff:02.1 Host bridge: Intel Corporation Core Processor QPI Physical 0 (rev 04) ff:03.0 Host bridge: Intel Corporation Core Processor Integrated Memory Controller (rev 04) ff:03.1 Host bridge: Intel Corporation Core Processor Integrated Memory Controller Target Address Decoder (rev 04) ff:03.4 Host bridge: Intel Corporation Core Processor Integrated Memory Controller Test Registers (rev 04) ff:04.0 Host bridge: Intel Corporation Core Processor Integrated Memory Controller Channel 0 Control Registers (rev 04) ff:04.1 Host bridge: Intel Corporation Core Processor Integrated Memory Controller Channel 0 Address Registers (rev 04) ff:04.2 Host bridge: Intel Corporation Core Processor Integrated Memory Controller Channel 0 Rank Registers (rev 04) ff:04.3 Host bridge: Intel Corporation Core Processor Integrated Memory Controller Channel 0 Thermal Control Registers (rev 04) ff:05.0 Host bridge: Intel Corporation Core Processor Integrated Memory Controller Channel 1 Control Registers (rev 04) ff:05.1 Host bridge: Intel Corporation Core Processor Integrated Memory Controller Channel 1 Address Registers (rev 04) ff:05.2 Host bridge: Intel Corporation Core Processor Integrated Memory Controller Channel 1 Rank Registers (rev 04) ff:05.3 Host bridge: Intel Corporation Core Processor Integrated Memory Controller Channel 1 Thermal Control Registers (rev 04) Update: I re-installed Ubuntu 12.04 (I assumed I messed something up while toying with it) but it did not solve the problem. Eventually, I got it to work with my school's wireless internet (the default network settings were wrong), but the internet still doesn't work on my apartment's wifi (it has no security on it).

    Read the article

  • tacacs+ integrated with LDAP or database. Which is better?

    - by chingupt
    We are setting up TACACS+ in our network which is a mix of Cisco AP's and other brands. However we have a centralized managemnet system which allows our customers to configure services. Hence we would like to setup a tacacs+ server integrated with some central system. We have two options: Integrate with a central Database server which stores the user configuration. OR Integrate with a LDAP Server. Which is a better solution? Can you please suggest the pros and cons of using LDAP or Database? TIA Sachin

    Read the article

  • How would you diagnose an integrated network card that doesn't show up on the device list?

    - by Tomer Gabel
    I've been setting up a server based around a Gigabyte GA-G33M-DS2R motherboard (G33, PCH9R with integrated Realtek 811B network device. I've enabled it in the BIOS, but it doesn't show up in the pre-boot PCI device list, isn't recognized by Windows (even after installing the chipset and networking drivers) and doesn't even show up via lspci. I've tried cycling power, disabling, cycling again, enabling, cycling again etc. to no avail. I'm sort of at a loss at this point; the board isn't under warranty anymore, but I'd rather not have to replace it. Any advice would be greatly appreciated...

    Read the article

  • How to edit the Boot Graphics Resource Table / Edit windows 8 BOOT LOGO?

    - by user144773
    I want to edit the screen which is displayed when windows 8 (starts) loads (/loading). As for now it has the Toshiba logo, I want my custom logo or the windows default logo. I have found that UEFI has something called "Boot Graphics Resource Table" and that it overides the default logo if there is a image present (source) How can I edit the logo stored in UEFI firmware or Boot Graphics Resource Table? if it's in the "bootres.dll", which does UEFI use? My disk (spread across a few system/usefi/windows/etc partitions) has around twenty bootres.dlls. The bootres.dll is signed by Microsoft, but I don't have to worry because I can sign the file I edit myself with my own certificate.

    Read the article

  • CustomButton Field not aligning in the center

    - by rupesh
    Hi all I have created a custom button and i am placing the bunch of Custombuttons in a verticalfieldManager , I have aligned the verticalField Manager in the center. when i am creating a default buttonField then verticalfield Manager is able to align the buttonfield in the center. but when i am assigning custombuttonfield in the verticalField Manager it's not aligning in the center. here is my custombuttoncode enter code herepublic CustomButtonField(String label,long style) { super(style); this.label = label; onPicture = Bitmap.getBitmapResource(onPicturePath); font = getFont(); this.setPadding(5,5, 5, 5); } public String getLabel() { return label; } public int getPreferredHeight() { return onPicture.getHeight(); } public int getPreferredWidth() { return onPicture.getWidth(); } protected void layout(int width , int height) { setExtent(Math.min(width, Display.getWidth()), Math.min(height,getPreferredHeight())); } protected void paint(Graphics graphics) { int texty =(getHeight()-getFont().getHeight())/2; if (isFocus()) { graphics.setColor(Color.BLACK); graphics.drawBitmap(0, 0, getWidth(), getHeight(),onPicture , 0, 0); graphics.setColor(Color.WHITE); graphics.setFont(font); graphics.drawText(label,0,texty,DrawStyle.ELLIPSIS,getWidth()); } else { graphics.drawBitmap(0, 0, getWidth(), getHeight(),onPicture , 0, 0); graphics.setColor(Color.WHITE); graphics.setFont(font); graphics.drawText(label,0,texty,DrawStyle.ELLIPSIS,getWidth()); } } public boolean isFocusable() { return true; } protected void onFocus(int direction) { super.onFocus(direction); invalidate(); } protected void onUnfocus() { super.onUnfocus(); invalidate(); } protected boolean navigationClick(int status, int time) { fieldChangeNotify(0); return true; } protected boolean keyChar(char character, int status, int time) { if (character == Keypad.KEY_ENTER) { fieldChangeNotify(0); return true; } return super.keyChar(character, status, time); } }

    Read the article

  • How can I stop IIS7 (integrated mode) from reporting a 404 before I get a chance to handle it?

    - by Gary McGill
    I have an ASP.NET MVC 2 application running on IIS7 in integrated mode. I'm trying to do my own 404 handling, but IIS7 seems to be intercepting the error and returning its own 404 message to the client before I get a chance to handle it. I'm not having much luck coming at the problem from a programming perspective over on Stack Overflow, so I wondered if maybe it's a configuration problem. Is there something I have to do to tell IIS to let me handle my own errors? (I'm trying to use Application_Error in my global.asax but it's not even getting there). There is a custom error page defined (at the machine level, I think) for 404 but when I tried removing that it didn't really help - it simply showed a bald one-liner message instead. My code still didn't get a look in. Is it perhaps something to do with the routing? Maybe the "mysite.com/nosuchpage" URL isn't being routed to me and that's why I don't get a chance to intercept it? Do I need to do something so that ALL requests get routed through my app?

    Read the article

< Previous Page | 84 85 86 87 88 89 90 91 92 93 94 95  | Next Page >