Search Results

Search found 894 results on 36 pages for 'philip gray'.

Page 13/36 | < Previous Page | 9 10 11 12 13 14 15 16 17 18 19 20  | Next Page >

  • Can a 10-bit monitor connection preserve all tones in 8-bit sRGB gradients on a wide-gamut monitor?

    - by hjb981
    This question is about color management and the use of a higher color depth, 10 bits per channel (30 bits in total, resulting in 1.07 billion colors, or 1024 shades of gray, sometimes referred to as "deep color") compared to the standard of 8 bits per channel (24 bits in total, 16.7 million colors, 256 shades of gray, sometimes referred to as "true color"). Do not confuse with "32 bit color", which usually refers to standard 8 bit color with an extra channel ("alpha channel") for transparency (used to achieve effects like semi-transparent windows etc). The following can be assumed to be in place: 1: A wide-gamut monitor that supports 10-bit input. Further, it can be assumed that the monitor has been calibrated to its native gamut and that an ICC color profile has been created. 2: A graphics card that supports 10-bit output (and is connected to the monitor via DisplayPort). 3: Drivers for the graphics card that support 10-bit output. If applications that support 10-bit output and color profiles would be used, I would expect them to display images that were saved using different color spaces correctly. For example, both an sRGB and an adobeRGB image should be displayed correctly. If an sRGB image was saved using 8 bits per channel (almost always the case), then the 10-bit signal path would ensure that no tonal gradients were lost in the conversion from the sRGB of the image to the native color space of the monitor. For example: If the image contains a pixel that is pure red in 8 bits (255,0,0), the corresponding value in 10 bits would be (1023,0,0). However, since the monitor has a larger color space than sRGB, sending the signal (1023,0,0) to the monitor would result in a red that was too saturated. Therefore, according to the ICC color profile, the signal would be transformed into a different value with less red saturation, for example (987,0,0). Since there are still plenty of levels left between 0 and 987, all 256 values (0-255) for red in the sRGB color space of the file could be uniquely mapped to color-corrected 10-bit values in the monitor's native color space. However, if the conversion was done in 8 bits, (255,0,0) would be translated to (246,0,0), and there would now only be 247 available levels for the red channel instead of 256, degrading the displayed image quality. My question is: how does this work on Ubuntu? Let's say that I use Firefox (which is color-aware and uses ICC color profiles). Would I get 10-bit processing, thus preserving all levels of an 8-bit picture? What is the situation like for other applications, especially photo applications like Shotwell, Rawtherapee, Darktable, RawStudio, Photivo etc? Does Ubuntu differ from other operating systems (Linux and others) on this point?

    Read the article

  • Oracle PartnerNetwork Exchange @ OPENWORLD 2012 - San Francisco

    - by Cinzia Mascanzoni
    Updates for you and to share with your partners: • OPN Exchange will kick off on Sunday, September 30th with Oracle Partner Keynote at 1pm PT and General Sessions at 3:30pm PT. • OPN Exchange AfterDark Reception featuring Macy Gray will be held at Metreon’s City View Terrace on Sunday, September 30th @ 7:30pm PT • Pre-enroll to attend 40+ OPN Exchange Sessions and Test Fest exams via Schedule Builder.

    Read the article

  • openGL textures in bitmap mode

    - by evenex_code
    For reasons detailed here I need to texture a quad using a bitmap (as in, 1 bit per pixel, not an 8-bit pixmap). Right now I have a bitmap stored in an on-device buffer, and am mounting it like so: glBindBuffer(GL_PIXEL_UNPACK_BUFFER, BFR.G[(T+1)%2]); glTexImage2D(GL_TEXTURE_2D, 0, GL_RGB, W, H, 0, GL_COLOR_INDEX, GL_BITMAP, 0); The OpenGL spec has this to say about glTexImage2D: "If type is GL_BITMAP, the data is considered as a string of unsigned bytes (and format must be GL_COLOR_INDEX). Each data byte is treated as eight 1-bit elements..." Judging by the spec, each bit in my buffer should correspond to a single pixel. However, the following experiments show that, for whatever reason, it doesn't work as advertised: 1) When I build my texture, I write to the buffer in 32-bit chunks. From the wording of the spec, it is reasonable to assume that writing 0x00000001 for each value would result in a texture with 1-px-wide vertical bars with 31-wide spaces between them. However, it appears blank. 2) Next, I write with 0x000000FF. By my apparently flawed understanding of the bitmap mode, I would expect that this should produce 8-wide bars with 24-wide spaces between them. Instead, it produces a white 1-px-wide bar. 3) 0x55555555 = 1010101010101010101010101010101, therefore writing this value ought to create 1-wide vertical stripes with 1 pixel spacing. However, it creates a solid gray color. 4) Using my original 8-bit pixmap in GL_BITMAP mode produces the correct animation. I have reached the conclusion that, even in GL_BITMAP mode, the texturer is still interpreting 8-bits as 1 element, despite what the spec seems to suggest. The fact that I can generate a gray color (while I was expecting that I was working in two-tone), as well as the fact that my original 8-bit pixmap generates the correct picture, support this conclusion. Questions: 1) Am I missing some kind of prerequisite call (perhaps for setting a stride length or pack alignment or something) that will signal to the texturer to treat each byte as 8-elements, as it suggests in the spec? 2) Or does it simply not work because modern hardware does not support it? (I have read that GL_BITMAP mode was deprecated in 3.3, I am however forcing a 3.0 context.) 3) Am I better off unpacking the bitmap into a pixmap using a shader? This is a far more roundabout solution than I was hoping for but I suppose there is no such thing as a free lunch.

    Read the article

  • Chris Brook-Carter at the Oracle Retail Week Awards VIP Reception

    - by user801960
    The Oracle VIP Reception at the Oracle Retail Week Awards last week saw retail luminaries from around the UK and Europe gather to have a drink and celebrate the successes of retail in the last year. Guests included Lord Harris of Peckham, Tesco's Philip Clarke, Vanessa Gold from Ann Summers, former Retail Week editor Tim Danaher, Richard Pennycook from Morrisons and Ian Cheshire from Kingfisher Group. The new Retail Week editor-in-chief, Chris Brook-Carter, attended and took the time to speak to the guests about the value of the Oracle Retail Week Awards to the industry and to thank Oracle for its dedication to supporting the industry. Chris said: "I'd like to say a real heartfelt thanks to our partner this evening: Oracle. I had the privilege of being at the judging day and I got to meet Sarah and the team and I was struck by not only the passion that they have for the whole awards system and everything that means in terms of rewarding excellence within the retail industry but also their commitment to retail in general, and it's that sort of relationship that marks out retail as such a fantastic sector to be involved in." Chris's speech can be watched in full below:

    Read the article

  • "Le problème que le XML résout n'est pas difficile, et il ne le résout pas bien": que manque-t-il le plus au langage ?

    L'essence du XML : le problème qu'il résout n'est pas difficile et il ne le résout pas correctement qu'est-ce qui manque le plus au langage Normalisé par le W3C, le langage XML (Extensible Markup Language) a été largement adopté comme format d'échange de données entre différents systèmes, plateformes et organisations. Mais, le langage a quelques faiblesses qui font souvent l'objet de plusieurs discussions et de rejet par certains. « The Essence Of Xml », l'un des documents fondamentaux sur le langage écrit par Philip Wadler et Jérôme Siméon procède à une analyse de celui-ci. Selon le document, les deux propriétés clés nécessaires pour n'importe quel format sont les suivant...

    Read the article

  • Apple publie la beta de Mac OS X Lion, une version pour les développeurs inspirée d'iOS

    Apple publie la beta Mac OS X Lion Une version de son OS pour les développeurs inspirée d'iOS Apple vient de mettre à la disposition des développeurs la première beta de son nouveau système d'exploitation Mac OS X Lion. Cette version s'inspire considérablement des idées qui ont donné naissance à l'iPad .« l'iPad a inspiré une nouvelle génération de fonctionnalités innovantes de Lion » affirme Philip Schiller, Vice président Marketing Produit. Au menu de ce nouveau système d'exploitation, on note l'arrivée du nouvel écran pour lancer les applications « Launchpad » qui permet d'accéder instantanément d'un simple clic à toutes les applications installées à la façon de l...

    Read the article

  • Un serveur de la Fondation Apache victime d'une attaque, des mots de passe utilisateurs auraient été

    Un serveur de la Fondation Apache victime d'une attaque Des mots de passe utilisateurs auraient été dérobés Des Hackers ont réussi à s'introduire dans un serveur que la Apache Software Foundation utilise pour le reporting des bugs de ses produits. Philip Gollucci, vice président des infrastructures chez Apache, rassure la communauté des développeurs "aucun code source n'a pu être affecté, en aucune manière". Les pirates, qui ne sont pas encore identifiés, auraient réussi leur intrusion dès le 6 avril en utilisant la méthode dite de "cross-site scripting". Ils auraient ensuite commencé à dérobé des mots de passe et des identifiants d'utilisateurs à partir...

    Read the article

  • XTerm and a bold text

    - by user610378
    This is my Xterm config: XTerm*saveLines: 512 XTerm*reverseVideo: false XTerm*reverseWrap: true XTerm*fullCursor: true XTerm*scrollTtyOutput: on XTerm*scrollKey: on XTerm*eightBitInput: false XTerm*pointerColor: white XTerm*pointerShape: left_ptr XTerm*charClass: 37:48,45-47:48,58:48,64:48,126:48 XTerm*cursorColor: rgb:aa/aa/aa XTerm*cursorColor2: black XTerm*color0: rgb:71/71/71 XTerm*color1: rgb:cd/00/00 XTerm*color2: rgb:b4/cd/00 XTerm*color3: rgb:cd/cd/00 XTerm*color4: rgb:71/71/71 XTerm*color5: rgb:cd/00/cd XTerm*color6: rgb:00/cd/cd XTerm*color7: rgb:e5/e5/e5 XTerm*color8: rgb:4c/4c/4c XTerm*color9: rgb:ff/00/00 XTerm*color10: rgb:55/ac/55 XTerm*color11: rgb:ff/ff/00 XTerm*color12: rgb:46/82/b4 XTerm*color13: rgb:ff/00/ff XTerm*color14: rgb:00/ff/ff XTerm*color15: rgb:ff/ff/ff XTerm*colorBD: white XTerm*colorUL: SkyBlue XTerm*colorBDMode: on XTerm*colorULMode: on XTerm*underLine: on XTerm*background: rgb:30/0a/24 XTerm*foreground: white XTerm*font: -*-monospace-medium-r-normal-9-140-*-*-m-*-* XTerm*font1: 5x7 XTerm*font2: 6x10 XTerm*font3: fixed XTerm*font4: 9x15 XTerm*ScrollBar.Background: gray XTerm*ScrollBar.thickness: 0 XTerm*ScrollBar.foreground: gray XTerm*ScrollBar: false XTerm*ScrollBar.DrawBorder: false XTerm*loginShell: true XTerm*faceName: Mono XTerm*faceSize: 9 Could anyone say is it possible to make bold some text, wich color is e.g. color1 from my config? I've tried XTerm*color1: rgb:cd/00/00 bold, but this doesn't work.

    Read the article

  • OS X Hard drive recovery

    - by Adam
    I am trying to recover data from a bad Seagate 1TB hard drive in a 2010 iMac. One day the iMac wouldn't boot (stuck at gray screen on startup). I removed the hard drive from the iMac and connected it to a MacBook using a 3.5" HDD to USB adapter. The hard drive wouldn't mount but it did display in Disk Utility that that there were 2 partitions on the disk. I tried to run Disk Warrior and it showed thousands of errors but still wouldn't mount. At this time the hard drive only show one partition in Disk Utility. Next I tried putting the hard drive in a desktop PC and running Spin Rite - which then gave me several division overflow errors (even with running Spin Rite with a newer version of DOS). The SMART status on the drive reports that the drive has had failures and HD Tune referenced the drive had once hit 59 degrees celsius. Disk Utility gives me the following message when running a pair: Error: Disk Utility can’t repair this disk. Back up as many of your files as possible, reformat the disk, and restore your backed-up files. Overall, the hard drive spins up and sounds OK - there are no clicking noises but the hard drive won't mount and displays as a light gray "Macintosh HD" in disk utility. Any tips or advice on how to recover data on this drive would be GREATLY appreciated! Are there any other tools I can try before calling it quits on this drive? Thank you

    Read the article

  • Choosing a VS project type (C++)

    - by typoknig
    Hi all, I do not use C++ much (I try to stick to the easier stuff like Java and VB.NET), but the lately I have not had a choice. When I am picking a project type in VS for some C++ source I download, what project type should I pick? I had just been sticking with Win32 Console Applications, but I just downloaded some code (below) that will not work right even when it compiles with out errors. I have tried to use a CLR Console Application and an empty project too, and have changed many variables along the way, but I cannot get this code to work. I noticed that this code does not have "int main()" at its beginning, does that have something to do with it? Anyways, here is the code, got it from here: /* Demo of modified Lucas-Kanade optical flow algorithm. See the printf below */ #ifdef _CH_ #pragma package <opencv> #endif #ifndef _EiC #include "cv.h" #include "highgui.h" #include <stdio.h> #include <ctype.h> #endif #include <windows.h> #define FULL_IMAGE_AS_OUTPUT_FILE #define cvMirror cvFlip //IplImage *image = 0, *grey = 0, *prev_grey = 0, *pyramid = 0, *prev_pyramid = 0, *swap_temp; IplImage **buf = 0; IplImage *image1 = 0; IplImage *imageCopy=0; IplImage *image = 0; int win_size = 10; const int MAX_COUNT = 500; CvPoint2D32f* points[2] = {0,0}, *swap_points; char* status = 0; //int count = 0; //int need_to_init = 0; //int night_mode = 0; int flags = 0; //int add_remove_pt = 0; bool bLButtonDown = false; //bool bstopLoop = false; CvPoint pt, pt1,pt2; //IplImage* img1; FILE* FileDest; char* strImageDir = "E:\\Projects\\TSCreator\\Images"; char* strItemName = "b"; int imageCount=0; int bFirstFace = 1; // flag for first face int mode = 1; // Mode 1 - Haar Traing Sample Creation, 2 - HMM sample creation, Mode = 3 - Both Harr and HMM. //int startImgeNo = 1; bool isEqualRation = false; //Weidth to height ratio is equal //Selected Image data IplImage *selectedImage = 0; int selectedX = 0, selectedY = 0, currentImageNo = 0, selectedWidth = 0, selectedHeight= 0; CvRect selectedROI; void saveFroHarrTraining(IplImage *src, int x, int y, int width, int height, int imageCount); void saveForHMMTraining(IplImage *src, CvRect roi,int imageCount); // Code for draw ROI Cropping Image void on_mouse( int event, int x, int y, int flags, void* param ) { char f[200]; CvRect reg; if( !image ) return; if( event == CV_EVENT_LBUTTONDOWN ) { bLButtonDown = true; pt1.x = x; pt1.y = y; } else if ( event == CV_EVENT_MOUSEMOVE ) //Draw the selected area rectangle { pt2.x = x; pt2.y = y; if(bLButtonDown) { if( !image1 ) { /* allocate all the buffers */ image1 = cvCreateImage( cvGetSize(image), 8, 3 ); image1->origin = image->origin; points[0] = (CvPoint2D32f*)cvAlloc(MAX_COUNT*sizeof(points[0][0])); points[1] = (CvPoint2D32f*)cvAlloc(MAX_COUNT*sizeof(points[0][0])); status = (char*)cvAlloc(MAX_COUNT); flags = 0; } cvCopy( image, image1, 0 ); //Equal Weight-Height Ratio if(isEqualRation) { pt2.y = pt1.y + (pt2.x-pt1.x); } //Max Height and Width is the image width and height if(pt2.x>image->width) { pt2.x = image->width; } if(pt2.y>image->height) { pt2.y = image->height; } CvPoint InnerPt1 = pt1; CvPoint InnerPt2 = pt2; if ( InnerPt1.x > InnerPt2.x) { int tempX = InnerPt1.x; InnerPt1.x = InnerPt2.x; InnerPt2.x = tempX; } if ( pt2.y < InnerPt1.y ) { int tempY = InnerPt1.y; InnerPt1.y = InnerPt2.y; InnerPt2.y = tempY; } InnerPt1.y = image->height - InnerPt1.y; InnerPt2.y = image->height - InnerPt2.y; CvFont font; double hScale=1.0; double vScale=1.0; int lineWidth=1; cvInitFont(&font,CV_FONT_HERSHEY_SIMPLEX|CV_FONT_ITALIC, hScale,vScale,0,lineWidth); char size [200]; reg.x = pt1.x; reg.y = image->height - pt2.y; reg.height = abs (pt2.y - pt1.y); reg.width = InnerPt2.x -InnerPt1.x; //print width and heght of the selected reagion sprintf(size, "(%dx%d)",reg.width, reg.height); cvPutText (image1,size,cvPoint(10,10), &font, cvScalar(255,255,0)); cvRectangle(image1, InnerPt1, InnerPt2, CV_RGB(255,0,0), 1); //Mark Selected Reagion selectedImage = image; selectedX = pt1.x; selectedY = pt1.y; selectedWidth = reg.width; selectedHeight = reg.height; selectedROI = reg; //Show the modified image cvShowImage("HMM-Harr Positive Image Creator",image1); } } else if ( event == CV_EVENT_LBUTTONUP ) { bLButtonDown = false; // pt2.x = x; // pt2.y = y; // // if ( pt1.x > pt2.x) // { // int tempX = pt1.x; // pt1.x = pt2.x; // pt2.x = tempX; // } // // if ( pt2.y < pt1.y ) // { // int tempY = pt1.y; // pt1.y = pt2.y; // pt2.y = tempY; // // } // //reg.x = pt1.x; //reg.y = image->height - pt2.y; // //reg.height = abs (pt2.y - pt1.y); ////reg.width = reg.height/3; //reg.width = pt2.x -pt1.x; ////reg.height = (2 * reg.width)/3; #ifdef FULL_IMAGE_AS_OUTPUT_FILE CvRect FullImageRect; FullImageRect.x = 0; FullImageRect.y = 0; FullImageRect.width = image->width; FullImageRect.height = image->height; IplImage *regionFullImage =0; regionFullImage = cvCreateImage(cvSize (FullImageRect.width, FullImageRect.height), image->depth, image->nChannels); image->roi = NULL; //cvSetImageROI (image, FullImageRect); //cvCopy (image, regionFullImage, 0); #else IplImage *region =0; region = cvCreateImage(cvSize (reg.width, reg.height), image1->depth, image1->nChannels); image->roi = NULL; cvSetImageROI (image1, reg); cvCopy (image1, region, 0); #endif //cvNamedWindow("Result", CV_WINDOW_AUTOSIZE); //selectedImage = image; //selectedX = pt1.x; //selectedY = pt1.y; //selectedWidth = reg.width; //selectedHeight = reg.height; ////currentImageNo = startImgeNo; //selectedROI = reg; /*if(mode == 1) { saveFroHarrTraining(image,pt1.x,pt1.y,reg.width,reg.height,startImgeNo); } else if(mode == 2) { saveForHMMTraining(image,reg,startImgeNo); } else if(mode ==3) { saveFroHarrTraining(image,pt1.x,pt1.y,reg.width,reg.height,startImgeNo); saveForHMMTraining(image,reg,startImgeNo); } else { printf("Invalid mode."); } startImgeNo++;*/ } } /* Save popsitive samples for Harr Training. Also add an entry to the PositiveSample.txt with the location of the item of interest. */ void saveFroHarrTraining(IplImage *src, int x, int y, int width, int height, int imageCount) { char f[255] ; sprintf(f,"%s\\%s\\harr_%s%d%d.jpg",strImageDir,strItemName,strItemName,imageCount/10, imageCount%10); cvNamedWindow("Harr", CV_WINDOW_AUTOSIZE); cvShowImage("Harr", src); cvSaveImage(f, src); printf("output%d%d \t ", imageCount/10, imageCount%10); printf("width %d \t", width); printf("height %d \t", height); printf("x1 %d \t", x); printf("y1 %d \t\n", y); char f1[255]; sprintf(f1,"%s\\PositiveSample.txt",strImageDir); FileDest = fopen(f1, "a"); fprintf(FileDest, "%s\\harr_%s%d.jpg 1 %d %d %d %d \n",strItemName,strItemName, imageCount, x, y, width, height); fclose(FileDest); } /* Create Sample Images for HMM recognition algorythm trai ning. */ void saveForHMMTraining(IplImage *src, CvRect roi,int imageCount) { char f[255] ; printf("x=%d, y=%d, w= %d, h= %d\n",roi.x,roi.y,roi.width,roi.height); //Create the file name sprintf(f,"%s\\%s\\hmm_%s%d.pgm",strImageDir,strItemName,strItemName, imageCount); //Create storage for grayscale image IplImage* gray = cvCreateImage(cvSize(roi.width,roi.height), 8, 1); //Create storage for croped reagon IplImage* regionFullImage = cvCreateImage(cvSize(roi.width,roi.height),8,3); //Croped marked region cvSetImageROI(src,roi); cvCopy(src,regionFullImage); cvResetImageROI(src); //Flip croped image - otherwise it will saved upside down cvConvertImage(regionFullImage, regionFullImage, CV_CVTIMG_FLIP); //Convert croped image to gray scale cvCvtColor(regionFullImage,gray, CV_BGR2GRAY); //Show final grayscale image cvNamedWindow("HMM", CV_WINDOW_AUTOSIZE); cvShowImage("HMM", gray); //Save final grayscale image cvSaveImage(f, gray); } int maina( int argc, char** argv ) { CvCapture* capture = 0; //if( argc == 1 || (argc == 2 && strlen(argv[1]) == 1 && isdigit(argv[1][0]))) // capture = cvCaptureFromCAM( argc == 2 ? argv[1][0] - '0' : 0 ); //else if( argc == 2 ) // capture = cvCaptureFromAVI( argv[1] ); char* video; if(argc ==7) { mode = atoi(argv[1]); strImageDir = argv[2]; strItemName = argv[3]; video = argv[4]; currentImageNo = atoi(argv[5]); int a = atoi(argv[6]); if(a==1) { isEqualRation = true; } else { isEqualRation = false; } } else { printf("\nUsage: TSCreator.exe <Mode> <Sample Image Save Path> <Sample Image Save Directory> <Video File Location> <Start Image No> <Is Equal Ratio>\n"); printf("Mode = 1 - Haar Traing Sample Creation. \nMode = 2 - HMM sample creation.\nMode = 3 - Both Harr and HMM\n"); printf("Is Equal Ratio = 0 or 1. 1 - Equal weidth and height, 0 - custom."); printf("Note: You have to create the image save directory in correct path first.\n"); printf("Eg: TSCreator.exe 1 E:\Projects\TSCreator\Images A 11.avi 1 1\n\n"); return 0; } capture = cvCaptureFromAVI(video); if( !capture ) { fprintf(stderr,"Could not initialize capturing...\n"); return -1; } cvNamedWindow("HMM-Harr Positive Image Creator", CV_WINDOW_AUTOSIZE); cvSetMouseCallback("HMM-Harr Positive Image Creator", on_mouse, 0); //cvShowImage("Test", image1); for(;;) { IplImage* frame = 0; int i, k, c; frame = cvQueryFrame( capture ); if( !frame ) break; if( !image ) { /* allocate all the buffers */ image = cvCreateImage( cvGetSize(frame), 8, 3 ); image->origin = frame->origin; //grey = cvCreateImage( cvGetSize(frame), 8, 1 ); //prev_grey = cvCreateImage( cvGetSize(frame), 8, 1 ); //pyramid = cvCreateImage( cvGetSize(frame), 8, 1 ); // prev_pyramid = cvCreateImage( cvGetSize(frame), 8, 1 ); points[0] = (CvPoint2D32f*)cvAlloc(MAX_COUNT*sizeof(points[0][0])); points[1] = (CvPoint2D32f*)cvAlloc(MAX_COUNT*sizeof(points[0][0])); status = (char*)cvAlloc(MAX_COUNT); flags = 0; } cvCopy( frame, image, 0 ); // cvCvtColor( image, grey, CV_BGR2GRAY ); cvShowImage("HMM-Harr Positive Image Creator", image); cvSetMouseCallback("HMM-Harr Positive Image Creator", on_mouse, 0); c = cvWaitKey(0); if((char)c == 's') { //Save selected reagion as training data if(selectedImage) { printf("Selected Reagion Saved\n"); if(mode == 1) { saveFroHarrTraining(selectedImage,selectedX,selectedY,selectedWidth,selectedHeight,currentImageNo); } else if(mode == 2) { saveForHMMTraining(selectedImage,selectedROI,currentImageNo); } else if(mode ==3) { saveFroHarrTraining(selectedImage,selectedX,selectedY,selectedWidth,selectedHeight,currentImageNo); saveForHMMTraining(selectedImage,selectedROI,currentImageNo); } else { printf("Invalid mode."); } currentImageNo++; } } } cvReleaseCapture( &capture ); //cvDestroyWindow("HMM-Harr Positive Image Creator"); cvDestroyAllWindows(); return 0; } #ifdef _EiC main(1,"lkdemo.c"); #endif If I put... #include "stdafx.h" int _tmain(int argc, _TCHAR* argv[]) { return 0; } ... before the previous code (and link it to the correct OpenCV .lib files) it compiles without errors, but does nothing at the command line. How do I make it work?

    Read the article

  • How to use css to change <pre> font size

    - by user289346
    pre{font-family:cursive;font-style:italic;font-size:xxx-small} how to change pre font size Hancock New Hampshire: Massachusetts: Rhode Island: Connecticut: New York: New Jersey: Pennsylvania: Josiah Bartlett, John Hancock, Stephen Hopkins, Roger Sherman, William Floyd, Richard Stockton, Robert Morris, William Whipple, Samuel Adams, William Ellery Samuel Huntington, Philip Livingston, John Witherspoon, Benjamin Franklin, Matthew Thornton

    Read the article

  • How to apply that resize method?

    - by Qpixo
    I noticed this full flash site and wonderring http://www.houseoforange.nl/site/#/Photographers/Philip%20Riches/editorial%20women/ How can I apply the resize method like the way they did? Any examples might help me a lot.

    Read the article

  • WPF Customized TabControl

    - by xsl
    I have to develop a customized tab control and decided to create it with WPF/XAML, because I planned to learn it anyway. It should look like this when it's finished: I made good progress so far, but there are two issues left: Only the first/last tab item should have a rounded upper-left/bottom-left corner. Is it possible to modify the style of these items, similar to the way I did with the selected tab item? The selected tab item should not have a border on its right side. I tried to accomplish this with z-index and overlapping, but the results were rather disappointing. Is there any other way to do this? XAML: <Window x:Class="MyProject.TestWindow" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Title="TestWindow" Height="350" Width="500" Margin="5" Background="LightGray"> <Window.Resources> <Style TargetType="{x:Type TabControl}"> <Setter Property="Template"> <Setter.Value> <ControlTemplate TargetType="{x:Type TabControl}"> <DockPanel> <Border Margin="0,100,-1,0" Background="#FFAAAAAA" BorderBrush="Gray" CornerRadius="7,0,0,7" BorderThickness="1"> <TabPanel Margin="0,0,0,0" IsItemsHost="True" /> </Border> <Border Background="WhiteSmoke" BorderBrush="Gray" BorderThickness="1" CornerRadius="7,7,7,0" > <ContentPresenter ContentSource="SelectedContent" /> </Border> </DockPanel> </ControlTemplate> </Setter.Value> </Setter> </Style> <Style TargetType="{x:Type TabItem}"> <Setter Property="Template"> <Setter.Value> <ControlTemplate TargetType="{x:Type TabItem}"> <Grid> <Border Name="Border" Background="#FFAAAAAA" CornerRadius="7,0,0,0" BorderBrush="Gray" BorderThickness="0,0,0,1" Margin="0,0,0,0"> <ContentPresenter x:Name="ContentSite" VerticalAlignment="Center" HorizontalAlignment="Left" ContentSource="Header" Margin="10,10,10,10"/> </Border> </Grid> <ControlTemplate.Triggers> <Trigger Property="IsSelected" Value="True"> <Setter TargetName="Border" Property="Background" Value="WhiteSmoke" /> </Trigger> </ControlTemplate.Triggers> </ControlTemplate> </Setter.Value> </Setter> </Style> </Window.Resources> <Grid> <TabControl Name="_menuTabControl" TabStripPlacement="Left" Margin="5"> <TabItem Name="_tabItem1" Header="First Tab Item" ></TabItem> <TabItem Name="_tabItem2" Header="Second Tab Item" > <Grid /> </TabItem> <TabItem Name="_tabItem3" Header="Third Tab Item" > <Grid /> </TabItem> </TabControl> </Grid>

    Read the article

  • Does anyone know how to layout a JToolBar that does't move or re-size any components placed in it?

    - by S1.Mac
    Can anyone help with this problem i'm trying to create a JToolBar and I want all its components to be fixed in size and position. I'v tried a few different layout managers but they all center and/or re-size the components when the frame its in is re-sized. here is an example using GridbagLayout, I have also used the default layout manager using the toolbar.add( component ) method but the result is the same : ' import java.awt.BorderLayout; import java.awt.Component; import java.awt.Dimension; import java.awt.GridBagConstraints; import java.awt.GridBagLayout; import javax.swing.*; public class ToolBarTest extends JFrame { private JToolBar toolbar; private JPanel mainPanel; private JPanel toolBarPanel; private JButton aButton; private JCheckBox aCheckBox; private JList aList; private Box toolbarBox; private GridBagConstraints toolbarConstraints; private GridBagLayout toolbarLayout; private JLabel shapeLabel; private JComboBox<ImageIcon> shapeChooser; private JLabel colorLabel; private JComboBox colorChooser; private String colorNames[] = { "Black" , "Blue", "Cyan", "Dark Gray", "Gray", "Green", "Light Gray", "Magenta", "Orange", "Pink", "Red", "White", "Yellow", "Custom" }; private String shapeNames[] = { "Line", "Oval", "Rectangle", "3D Rectangle","Paint Brush", "Rounded Rectangle" }; public ToolBarTest() { setLayout( new BorderLayout() ); setDefaultCloseOperation( JFrame.EXIT_ON_CLOSE ); setSize( 500, 500 ); add( createToolBar(), BorderLayout.PAGE_START ); setVisible( true ); } public void addToToolbar( Component component, int row, int column ) { toolbarConstraints.gridx = column; toolbarConstraints.gridy = row; toolbarConstraints.anchor = GridBagConstraints.WEST; toolbarConstraints.fill = GridBagConstraints.NONE; toolbarConstraints.weightx = 0; toolbarConstraints.weighty = 0; toolbarConstraints.gridwidth = 1; toolbarConstraints.gridheight = 1; toolbarLayout.setConstraints( component, toolbarConstraints ); toolbar.add( component ); }// end addToToolbar public final JToolBar createToolBar() { toolbarLayout = new GridBagLayout(); toolbarConstraints = new GridBagConstraints(); // create the tool bar which holds the items to draw toolbar = new JToolBar(); toolbar.setBorderPainted(true); toolbar.setLayout( toolbarLayout ); toolbar.setFloatable( true ); shapeLabel = new JLabel( "Shapes: " ); addToToolbar( shapeLabel, 0, 1 ); String iconNames[] = { "PaintImages/Line.jpg", "PaintImages/Oval.jpg", "PaintImages/Rect.jpg", "PaintImages/3DRect.jpg","PaintImages/PaintBrush.jpg", "PaintImages/RoundRect.jpg"}; ImageIcon shapeIcons[] = new ImageIcon[ shapeNames.length ]; // create image icons for( int shapeButton = 0; shapeButton < shapeNames.length; shapeButton++ ) { shapeIcons[ shapeButton ] = new ImageIcon( iconNames[ shapeButton ] ); }// end for shapeChooser = new JComboBox< ImageIcon >( shapeIcons ); shapeChooser.setSize( new Dimension( 50, 20 )); shapeChooser.setPrototypeDisplayValue( shapeIcons[ 0 ] ); shapeChooser.setSelectedIndex( 0 ); addToToolbar( shapeChooser, 0, 2 ); colorLabel = new JLabel( "Colors: " ); addToToolbar( colorLabel, 0, 3 ); colorChooser = new JComboBox( colorNames ); addToToolbar( colorChooser, 0, 4 ); return toolbar; }// end createToolBar public static void main( String args[] ) { new ToolBarTest(); }// end main }// end class ToolBarTest'

    Read the article

  • Transform your Oracle Tutor Documents to Your Corporate Standard

    - by mary.keane
    You have all of your company's processes documented in Oracle Tutor, and now you want to get the HTML files to reflect your company's corporate look and feel. How are you going to do this without having an HTML guru to change every HTML page? The good news is you do not need to be an HTML expert to make minor changes to your documents. All Tutor HTML files are attached to a group of style sheets, so any changes you make to the style sheets will immediately be reflected in all of your HTML documents. If you want to give it a try, here's what you do (please note that these tips are applicable to release Oracle Tutor 12.2 and greater): Navigate to your Tutor HTML directory, and copy into a draft folder a representative group of HTML files (don't forget the flowchart image files that are associated with the procedures). You'll also need to copy the following files: tutor.css tutor_notabs.css tutor_scripts.js tutor_tabs.css flow_icon.gif Here's the default look to the Oracle Tutor desk manual. Let's say I want to use my company's corporate style in the HTML documents. At Oracle, we use Oracle Red (FF0000), Oracle Black (000000), and Oracle Gray (666666). So I want to incorporate those colors into the Tutor HTML files. I open tutor.css from the draft folder in a text editor. My preference is to use Notepad, but there are others. Make sure, however, that it is a text editor, and not a word processing program. I want to change the headings to Oracle Red. The desk manual title is listed as the DMPAGETITLE, so I find that in tutor.css. The style names in the style sheets are descriptive, but sometimes you may have to experiment to find the right style (this is why you're working in a draft folder). I change the color attribute to FF00000, and then I save the document. Now I look at one of the desk manuals in my draft folder. I've successfully changed the title of the desk manual, so, now that I have more confidence that I can do this, I start changing other styles. I need to make changes in the tutor_tabs.css file as well, so I open that document. Then I look at one of the procedures. Oops! All that red is distracting, and the users may not be able to follow their procedures. So I go back to the corporate style guide, and I find some shades of gray that have been approved. So I use that, and it is now more readable. It's good enough for a first draft, and I would show it to my colleagues at this point to get their input. On my next blog, I'll discuss how to change the flowchart colors to match your corporate look and feel. Have you used the cascading styles sheets to change the look of your Tutor documents? If so, let us know what you've done in your post. Mary R. Keane Senior Development Manager, Oracle Tutor & UPK Content

    Read the article

  • Math with Timestamp

    - by Knut Vatsendvik
    table.sql { border-width: 1px; border-spacing: 2px; border-style: dashed; border-color: #0023ff; border-collapse: separate; background-color: white; } table.sql th { border-width: 1px; padding: 1px; border-style: none; border-color: gray; background-color: white; -moz-border-radius: 0px 0px 0px 0px; } table.sql td { border-width: 1px; padding: 3px; border-style: none; border-color: gray; background-color: white; -moz-border-radius: 0px 0px 0px 0px; } .sql-keyword { color: #0000cd; background-color: inherit; } .sql-result { color: #458b74; background-color: inherit; } Got this little SQL quiz from a colleague.  How to add or subtract exactly 1 second from a Timestamp?  Sounded simple enough at first blink, but was a bit trickier than expected. If the data type had been a Date, we knew that we could add or subtract days, minutes or seconds using + or – sysdate + 1 to add one day sysdate - (1 / 24) to subtract one hour sysdate + (1 / 86400) to add one second Would the same arithmetic work with Timestamp as with Date? Let’s test it out with the following query SELECT   systimestamp , systimestamp + (1 / 86400) FROM dual; ---------- 03.05.2010 22.11.50,240887 +02:00 03.05.2010 The first result line shows us the system time down to fractions of seconds. The second result line shows the result as Date (as used for date calculation) meaning now that the granularity is reduced down to a second.   By using the PL/SQL dump() function, we can confirm this with the following query SELECT   dump(systimestamp) , dump(systimestamp + (1 / 86400)) FROM dual; ---------- Typ=188 Len=20: 218,7,5,4,8,53,9,0,200,46,89,20,2,0,5,0,0,0,0,0 Typ=13 Len=8: 218,7,5,4,10,53,10,0 Where typ=13 is a runtime representation for Date. So how can we increase the precision to include fractions of second? After investigating it a bit, we found out that the interval data type INTERVAL DAY TO SECOND could be used with the result of addition or subtraction being a Timestamp. Let’s try again our first query again, now using the interval data type. SELECT systimestamp,    systimestamp + INTERVAL '0 00:00:01.0' DAY TO SECOND(1) FROM dual; ---------- 03.05.2010 22.58.32,723659000 +02:00 03.05.2010 22.58.33,723659000 +02:00 Yes, it worked! To finish the story, here is one example showing how to specify an interval of 2 days, 6 hours, 30 minutes, 4 seconds and 111 thousands of a second. INTERVAL ‘2 6:30:4.111’ DAY TO SECOND(3)

    Read the article

  • Grub2 : Windows 7 can't boot installing with Ubuntu 10.04 on different hard drive

    - by dellphi
    I use a dual boot with two hard disks and two OS is Ubuntu 10.04 and Windows 7. Windows 7 installed on the first disk, first partition. Grub is installed on a second hard disk MBR, and Ubuntu installed on an extended partition on a second hard drive. When I select Windows 7 on the Grub menu, the HDD lamp lights up briefly and then black screen on the monitor, with the status of the keyboard is still functioning. Until now (with the default boot from first HDD), I have to press F12 to get into the Grub to run Linux on a second HDD. ================ fdisk -l ================================ dellph1@dellph1-desktop:~$ fdisk -l omitting empty partition (5) Disk /dev/sda: 1000.2 GB, 1000204886016 bytes 255 heads, 63 sectors/track, 121601 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00087dec Device Boot Start End Blocks Id System /dev/sda1 * 1 23104 185582848+ 7 HPFS/NTFS /dev/sda2 23105 121601 791177122 5 Extended /dev/sda5 36107 74408 307660783+ 7 HPFS/NTFS /dev/sda6 74409 100081 206218341 7 HPFS/NTFS /dev/sda7 100082 121601 172859368+ 7 HPFS/NTFS Disk /dev/sdb: 160.0 GB, 160041885696 bytes 255 heads, 63 sectors/track, 19457 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x6d43dfb2 Device Boot Start End Blocks Id System /dev/sdb1 1 10030 80560066 5 Extended /dev/sdb5 * 1 5560 44657601 83 Linux /dev/sdb6 5560 9387 30736384 83 Linux /dev/sdb7 9387 10030 5164032 82 Linux swap / Solaris dellph1@dellph1-desktop:~$ ================= grub.cfg ================== # DO NOT EDIT THIS FILE # It is automatically generated by /usr/sbin/grub-mkconfig using templates from /etc/grub.d and settings from /etc/default/grub # BEGIN /etc/grub.d/00_header if [ -s $prefix/grubenv ]; then load_env fi set default="0" if [ ${prev_saved_entry} ]; then set saved_entry=${prev_saved_entry} save_env saved_entry set prev_saved_entry= save_env prev_saved_entry set boot_once=true fi function savedefault { if [ -z ${boot_once} ]; then saved_entry=${chosen} save_env saved_entry fi } function recordfail { set recordfail=1 if [ -n ${have_grubenv} ]; then if [ -z ${boot_once} ]; then save_env recordfail; fi; fi } insmod ext2 set root='(hd1,5)' search --no-floppy --fs-uuid --set 2f014a3a-35f3-4d05-87aa-34ca677160b7 if loadfont /usr/share/grub/unicode.pf2 ; then set gfxmode=1024x768 insmod gfxterm insmod vbe if terminal_output gfxterm ; then true ; else # For backward compatibility with versions of terminal.mod that don't # understand terminal_output terminal gfxterm fi fi insmod ext2 set root='(hd1,5)' search --no-floppy --fs-uuid --set 2f014a3a-35f3-4d05-87aa-34ca677160b7 set locale_dir=($root)/boot/grub/locale set lang=en insmod gettext if [ ${recordfail} = 1 ]; then set timeout=-1 else set timeout=5 fi END /etc/grub.d/00_header BEGIN /etc/grub.d/05_debian_theme insmod ext2 set root='(hd1,5)' search --no-floppy --fs-uuid --set 2f014a3a-35f3-4d05-87aa-34ca677160b7 insmod jpeg if background_image /usr/share/backgrounds/CurlsbyCandy.jpg ; then set color_normal=white/black set color_highlight=black/light-gray else set menu_color_normal=white/black set menu_color_highlight=black/light-gray fi END /etc/grub.d/05_debian_theme BEGIN /etc/grub.d/10_linux menuentry 'Ubuntu, with Linux 2.6.32-24-generic' --class ubuntu --class gnu-linux --class gnu --class os { recordfail insmod ext2 set root='(hd1,5)' search --no-floppy --fs-uuid --set 2f014a3a-35f3-4d05-87aa-34ca677160b7 linux /boot/vmlinuz-2.6.32-24-generic root=UUID=2f014a3a-35f3-4d05-87aa-34ca677160b7 ro splash vga=795 quiet splash nomodeset video=uvesafb:mode_option=1280x1024-24,mtrr=3,scroll=ywrap initrd /boot/initrd.img-2.6.32-24-generic } menuentry 'Ubuntu, with Linux 2.6.32-24-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os { recordfail insmod ext2 set root='(hd1,5)' search --no-floppy --fs-uuid --set 2f014a3a-35f3-4d05-87aa-34ca677160b7 echo 'Loading Linux 2.6.32-24-generic ...' linux /boot/vmlinuz-2.6.32-24-generic root=UUID=2f014a3a-35f3-4d05-87aa-34ca677160b7 ro single splash vga=795 echo 'Loading initial ramdisk ...' initrd /boot/initrd.img-2.6.32-24-generic } END /etc/grub.d/10_linux BEGIN /etc/grub.d/30_os-prober menuentry "Windows 7 (loader) (on /dev/sda1)" { insmod ntfs set root='(hd0,1)' search --no-floppy --fs-uuid --set 5cac2139ac210f58 chainloader +1 } END /etc/grub.d/30_os-prober BEGIN /etc/grub.d/40_multisystem Ajout de MultiSystem MULTISYSTEM MENU menuentry "PLoP Boot Manager" { linux16 /boot/plpbt } menuentry "Smart Boot Manager" { search --set -f /boot/sbootmgr.dsk linux16 /boot/memdisk initrd16 /boot/sbootmgr.dsk } FIN MULTISYSTEM MENU END /etc/grub.d/40_multisystem ================================================ I want to keep the Grub on the second HDD. I have been using the Startup Manager, Boot Manager and Grub Customizer, and this problem still unsolved. The easiest thing that I can possibly do is to install Grub on first HDD, but I was curious and maybe someone can help.

    Read the article

  • Set UIViewController background to transparent

    - by dbonneville
    I'm calling a UIViewController from a button on the main view. I have set the alpha of the view to 50%. When the view animates in, I can see that it's transparent. As soon as the animation stops, it becomes opaque. In the xib, when I set opacity, it's sets the opacity over white. So if I set the color to black and the opacity to 50%, this is what I see when I click the button on the main interface to show the view: view slides up from bottom at 50% opacity. I can see the underlaying view through the transparent black nicely. when view stops animating, it become gray. it appears that a white color pops in the background of the view somehow, making the 50% opacity black over white turn gray. I can no longer see the underlaying layer. What I'm trying to do: show 100% white text on a 50% transparent black layer which sits over the view that called this view. How on earth do I do this? I tried a code method that sets the background color when the view is called, but it does exactly the same thing (with another try in there commented out with the same effect): - (IBAction)gotoCreed { Creed *creed = [[Creed alloc] initWithNibName:nil bundle:nil]; [self presentModalViewController:creed animated:YES]; self.view.backgroundColor = [UIColor colorWithHue:0.0 saturation:0.0 brightness:1.0 alpha:0.2]; //self.view.backgroundColor = [UIColor clearColor]; }

    Read the article

  • DEVX Web chart control

    - by Minal
    i am using DEVX Webchart control.. Bind x-Axis values: <dxchartsui:WebChartControl ID="ChartOPCGraph" runat="server" Height="400px" Width="700px" ClientInstanceName="ChartOPCGraph" DiagramTypeName="XYDiagram"> <Diagram> <axisy> <gridlines visible="False"></gridlines> </axisy> </Diagram> <Titles> <cc1:ChartTitle Dock="Bottom" Font="Tahoma, 8pt" Text="Days" TextColor="Gray" Alignment="Center"> </cc1:ChartTitle> <cc1:ChartTitle Dock="Left" Font="Tahoma, 8pt" Text="% Payment made" TextColor="Gray" Alignment="Center"></cc1:ChartTitle> </Titles> </dxchartsui:WebChartControl> values are being populated from database. On x-axis only two number comes from database so i need to bind only these two values and rest of them must not be visible. For example i get 9 number from database and it binds 8.6,8.7,8.8,8.9,9,9.2,...... Need a quick reply..

    Read the article

  • UIImage cropping on user selected rectangle in iphone?

    - by Rajendra Bhole
    Hi, I developing an small application in which i want to crop the UIImage captured by imagePickerControllerSourceTypeOfCamera. The UIImage should crop by user selected crop area or cropped rectangle. That means first user capture the image from the camera.Then on captured image the user selected an rectangle having color gray.That image(image data) should crop from that gray colored rectangle. My under develop code is as follows. -(IBAction) getPhoto:(id)sender { UIImagePickerController* imagePickerController = [[UIImagePickerController alloc] init]; imagePickerController.delegate = self; if((UIButton *) sender == btnphotoAlbum) { imagePickerController.sourceType = UIImagePickerControllerSourceTypePhotoLibrary; } else { imagePickerController.sourceType = UIImagePickerControllerSourceTypeCamera; } imagePickerController.allowsImageEditing = YES; //imagePickerController.toolbar.barStyle =UIBarStyleBlackOpaque; //UIToolbar *toolBar=[[UIToolbar alloc] initWithFrame:CGRectMake(0, 0, 20, 320)]; //imagePickerController. [self presentModalViewController:imagePickerController animated:YES]; } (void)imagePickerController:(UIImagePickerController *)picker didFinishPickingImage:(UIImage *)image editingInfo:(NSDictionary *)editingInfo { UIImage *selectedImage = image; UIImage *originalImage = [editingInfo objectForKey:@"UIImagePickerControllerOriginalImage"]; NSValue *cropRect = [editingInfo objectForKey:UIImagePickerControllerCropRect]; CGRect theRect = [cropRect CGRectValue]; //captureImage.image =[info objectForKey:@"UIImagePickerControllerOriginalImage"]; [picker dismissModalViewControllerAnimated:YES]; } How i crop the image?

    Read the article

  • Double buffering with C# has negative effect

    - by Roland Illig
    I have written the following simple program, which draws lines on the screen every 100 milliseconds (triggered by timer1). I noticed that the drawing flickers a bit (that is, the window is not always completely blue, but some gray shines through). So my idea was to use double-buffering. But when I did that, it made things even worse. Now the screen was almost always gray, and only occasionally did the blue color come through (demonstrated by timer2, switching the DoubleBuffered property every 2000 milliseconds). What could be an explanation for this? using System; using System.Drawing; using System.Windows.Forms; namespace WindowsFormsApplication1 { public partial class Form1 : Form { public Form1() { InitializeComponent(); } private void Form1_Paint(object sender, PaintEventArgs e) { Graphics g = CreateGraphics(); Pen pen = new Pen(Color.Blue, 1.0f); Random rnd = new Random(); for (int i = 0; i < Height; i++) g.DrawLine(pen, 0, i, Width, i); } // every 100 ms private void timer1_Tick(object sender, EventArgs e) { Invalidate(); } // every 2000 ms private void timer2_Tick(object sender, EventArgs e) { DoubleBuffered = !DoubleBuffered; this.Text = DoubleBuffered ? "yes" : "no"; } } }

    Read the article

  • Nested table height in TCPDF

    - by Kuroki Kaze
    Is it possible to make nested table fit height of its parent cell in TCPDF? My code: <?php require_once('tcpdf/config/lang/eng.php'); require_once('tcpdf/tcpdf.php'); $pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false); $pdf->setPrintHeader(false); $pdf->setPrintFooter(false); $pdf->SetFont('times', 'BI', 8); $pdf->AddPage(); $pdf->writeHTML('<table> <tr><td bgcolor="gray"> Angoisse et vif espoir, sans humeur factieuse.<br/> Plus allait se vidant le fatal sablier,<br/> Plus ma torture était âpre et délicieuse;<br/> Tout mon coeur s’arrachait au monde familier</td> <td bgcolor="lightgray">Second</td> <td bgcolor="gray">Third</td> <td> <table style="height: 100%"> <tr bgcolor="blue" style="height: 30%"><td bgcolor="yellow" style="height: 30%">Ichi</td></tr> <tr bgcolor="white" style="height: 30%"><td bgcolor="cyan" style="height: 30%">Ni</td></tr> <tr bgcolor="blue" style="height: 30%"><td bgcolor="yellow" style="height: 30%">San</td></tr> </table> </td></tr> </table>'); $pdf->Output('example_002.pdf', 'I'); ?> I want table in last cell to fill it entirely. Is there any way to do this?

    Read the article

  • Latex: Listings with monospace fonts

    - by Nils
    This is what the code looks in Xcode. And this in my listing created with texlive. And yes I used basicstyle=\ttfamily . Having looked at the manual of listings I haven't found anything about fixed-with or monospace fonts.. Example to reproduce \documentclass[ article, a4paper, a4wide, %draft, smallheadings ]{book} % Packages below \usepackage{graphicx} \usepackage{verbatim} % used to display code \usepackage{hyperref} \usepackage{fullpage} \usepackage[ansinew]{inputenc} % german umlauts \usepackage[usenames,dvipsnames]{color} \usepackage{float} \usepackage{subfig} \usepackage{tikz} \usetikzlibrary{calc,through,backgrounds} \usepackage{fancyvrb} \usepackage{acronym} \usepackage{amsthm} % Uuhhh yet another package \VerbatimFootnotes % Required, otherwise verbatim does not work in footnotes! \usepackage{listings} \definecolor{Brown}{cmyk}{0,0.81,1,0.60} \definecolor{OliveGreen}{cmyk}{0.64,0,0.95,0.40} \definecolor{CadetBlue}{cmyk}{0.62,0.57,0.23,0} \definecolor{lightlightgray}{gray}{0.9} \begin{document} \lstset{ language=C, % Code langugage basicstyle=\ttfamily, % Code font, Examples: \footnotesize, \ttfamily keywordstyle=\color{OliveGreen}, % Keywords font ('*' = uppercase) commentstyle=\color{gray}, % Comments font numbers=left, % Line nums position numberstyle=\tiny, % Line-numbers fonts stepnumber=1, % Step between two line-numbers numbersep=5pt, % How far are line-numbers from code backgroundcolor=\color{lightlightgray}, % Choose background color frame=none, % A frame around the code tabsize=2, % Default tab size captionpos=b, % Caption-position = bottom breaklines=true, % Automatic line breaking? breakatwhitespace=false, % Automatic breaks only at whitespace? showspaces=false, % Dont make spaces visible showtabs=false, % Dont make tabls visible columns=flexible, % Column format morekeywords={__global__, __device__}, % CUDA specific keywords } \begin{lstlisting} As[threadRow][threadCol] = A[ threadCol + threadRow * Awidth // Adress of the thread in the current block + i * BLOCK_SIZE // Pick a block further left for i+1 + blockRow * BLOCK_SIZE * Awidth // for blockRow +1 go one blockRow down ]; \end{lstlisting} \end{document}

    Read the article

< Previous Page | 9 10 11 12 13 14 15 16 17 18 19 20  | Next Page >