title: 'Clipbrd' in Delphi is corrupt
body: <p>When using the unit <code>Clipbrd</code>, anyone know of text corruption that happens?</p>
  <p>After accessing bitmap</p>
  <pre><code>    bitmap.Assign(Clipboard);
  </code></pre>
  <p>Text from the clipboard seems to be corrupted. With English it works fine, however it shifts to strange characters such as
  <code>ã</code></p>
  <p>Is this an &quot;open bug&quot;?</p>
  <p>Is there a way to handle this and return the clipboard to its normal operations without restarting the computer?</p>
  <h3>The code</h3>
  <pre><code>Clipboard.Open;
  bitmap.Assign(Clipboard);
  Clipboard.Close;
  </code></pre>
  <p>Results in the same results.</p>
  <p>My guess is it goes to somewhere with encoding.</p>
  <p>Their corruption of the clipboard is for user experience outside the software. The clipboard become non useable for non-English languages.</p>
  <p>After any the extraction of a pic, the clipboard cannot transfer non-English even after Delphi is shut down, or the software.</p>
  <p>I am testing with:</p>
  <blockquote>
  <p>大日本帝國</p>
  </blockquote>
  <p>Copy and paste result:</p>
  <pre><code>?????
  
  unit Unit4;
  
  interface
  
  uses
    Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
    Dialogs, ExtCtrls, Clipbrd, StdCtrls;
  
  type
    TForm4 = class(TForm)
      img1: TImage;
      btn1: TButton;
      procedure btn1Click(Sender: TObject);
    private
      { Private declarations }
    public
      { Public declarations }
    end;
  
  var
    Form4: TForm4;
  
  implementation
  
  {$R *.dfm}
  
  procedure TForm4.btn1Click(Sender: TObject);
  var
  bitmap : TBitmap;
  begin
    bitmap := TBitmap.Create;
    bitmap.Assign(Clipboard);
    img1.picture.Assign(bitmap);
    FreeAndNil(bitmap);
  end;
  
  end.
  </code></pre>
  <p>dfm :</p>
  <pre><code>object Form4: TForm4
    Left = 0
    Top = 0
    Caption = 'Form4'
    ClientHeight = 282
    ClientWidth = 418
    Color = clBtnFace
    Font.Charset = DEFAULT_CHARSET
    Font.Color = clWindowText
    Font.Height = -11
    Font.Name = 'Tahoma'
    Font.Style = []
    OldCreateOrder = False
    PixelsPerInch = 96
    TextHeight = 13
    object img1: TImage
      Left = 168
      Top = 64
      Width = 105
      Height = 105
    end
    object btn1: TButton
      Left = 184
      Top = 232
      Width = 75
      Height = 25
      Caption = 'btn1'
      TabOrder = 0
      OnClick = btn1Click
    end
  end
  </code></pre>
  <ul>
  <li>Compile and execute.</li>
  <li>Go to start → <em>Run</em></li>
  <li>Then type in (do not copy from here!)</li>
  </ul>
  <blockquote>
  <p>יגדכלחילדגחכי</p>
  </blockquote>
  <p>Then paste back, and you would get</p>
  <blockquote>
  <p>éâãëìçéìãâçëé</p>
  </blockquote>