erase

How does a 7- or 35-pass erase work? Why would one use these methods?

How and why do 7- and 35-pass erases work? Shouldn't a simple rewrite with all zeroes be enough? ...

How do I erase printed characters in a console application(Linux)?

Hi all, I am creating a small console app that needs a progress bar. Something like... Conversion: 175/348 Seconds |========== | 50% My question is, how do you erase characters already printed to the console? When I reach the 51st percentage, I have to erase this line from the console and insert a new line. In my current ...

Deleting files securely in delphi7

Problem I want to securely delete a file in windows XP. Context I need to delete my input file securely once i have finished with it, at the moment i am over writing all the data with zero, this is messy as my temp folder becomes full of old files also the name of the files is a security issue, rather than just moving them to the recycl...

C++ STL map::erase a non-existing key

Regarding the C++ STL map, erasing by key:- size_type map::erase ( const key_type& x ); Is it legal to erase a non-existing key? i.e. is the snippet below ok? map<char,int> mymap; mymap['c']=30; mymap.erase('c'); mymap.erase('c'); mymap.erase('D'); Cheers ...

How to erase element from std::vector<> by index?

If I have a std::vector and I want to delete the x'th element how to do it? std::vector<int> vec; vec.push_back(6); vec.push_back(-17); vec.push_back(12); vec.erase(???); Please help! ...

How to erase & delete pointers to objects stored in a vector?

I have a vector that stores pointers to many objects instantiated dynamically, and I'm trying to iterate through the vector and remove certain elements (remove from vector and destroy object), but I'm having trouble. Here's what it looks like: vector<Entity*> Entities; /* Fill vector here */ vector<Entity*>::iterator it; ...

Disabling/Overriding some Javascript from Webbrowser Control using Inject?

I am trying to access a page that has certain javascript that causes errors and prevents the page from fully rendering. <script language="Javascript"> parent.hidden.vPageState = parent.hidden.NEW_LIST; </script> and <body onload="top.menu.activateCell(3);"> Both of these errors are related to the fact that I am accessing the page ...

C# : How to erase content on a Bitmap

Hi I have C# winForm application which holds a pictureBox control. This control has a Paint event.Every time paint event is fired , a Bitmap is dynamically created and I perform some drawing on it. And when user clicks "save" button , edited image is saved as jpg file. It's OK until now. But when I load a new image in pictureBox contr...

completely removing a vector c++

Hi , I'm having problems removing a vector from a "multidimensional vector" I would like to achieve this: 1 1 1 1 1 1 1 1 2 2 2 2 2 2 2 2 3 3 3 3 4 4 4 4 4 4 4 4 for example vector<vector<int>>vec; for i...//give vec values... vec[3].erase(vec.begin(),vec.end()); It seems like us...

how to erase some portion of uiimageview's image in iphone?

i have a view with uimageview and an image set to it. i want to erase image as something like we do in photoshop with an eraser.how do i achieve this.also how do i undo erase??? ...

How can I erase the current line printed on console in C ? I am working on a linux system

How can I erase the current line printed on console in C ? I am working on a linux system example - printf("hello"); printf("bye"); I want to print bye on the same line in place of hello. output bye ...

Problem with actionscript 3 erasing drawing

I have a based image and some sprites on top of the basd image movieclip... Some of the sprites can be drawn by the user using graphics api in actionscript 3. I can draw things on the sprites but I can't create an eraser like brush that can remove part of the unwanted drawings. I try using Alpha but no it doesn't work I have googled ab...

How to clear and then redraw a quartz drawing

I'm making a complex drawing using quartz based on passed in information. The only part I haven't been able to figure out is how do I clear the lines, rectangles, etc that I've already drawn? Basically, I want to erase the whole drawing and just draw it again from the new data. ...

Erase-remove idiom: what happens when remove return past-the-end-iterator?

I got this question when I was reading erase-remove idiom (item 32) from Scott Meyers "Effective STL” book. vector<int> v; ... v.erase(remove(v.begin(), v.end(), 99), v.end()); remove basically returns the "new logical end” and elements of the original range that start at the "new logical end" of the range and continue until the real...

How to erase old queries in @logger using Ruby on Rails

Hi All, I'm developing an application using Ruby on Rails. I would like to erase old queries in the ActiveRecord::Base.logger object every time when i call a new action, essentially where ENV = production. Thanks a lot Mondher ...

Erasing in a WPF program

How can I make a MS Paint clone in WPF? I use Canvas and Shapes, but I don't know how to implement erasing. Should I use different controls, image control for example, or other drawing technology? ...

C++ - Deleting a vector element that is referenced by a pointer

Hi all! Well, I don't know if it is possible, but the thing would be: struct stPiece { /* some stuff */ stPiece *mother; // pointer to the piece that created this one }; vector<stPiece> pieces; Is it possible to erase the piece referenced by 'mother' from pieces, having just that pointer as a reference? How? Would it mess with t...

Qt painted content goes lost

Hi All, I am writing an info-screen program. I created a full-screen widget and draw contents onto it. In order to extend the life cycle of the TFT-display device, I want to implement a pixel-shifting feature. With other words, in every X minutes, I shift the screen to left/right/top/down for Y pixels. My approach is as follows: I ...

unlink vs remove in c++

Hi. What is the difference between remove and unlink functions in C++? Thanks. ...

CGContextClearRect working slow

Hello, Do anyone know how I can draw a transparent portion of image using CGContextClearRect with best performance? My requirements is that I need to draw a mask on a picture, in some cases, I need to erase it, but CGContextClearRect working slow. I have use CGContextAddElipse to draw circle to clear the image. Great help will be apprec...