導航:首頁 > 編程語言 > qq截圖代碼實現

qq截圖代碼實現

發布時間:2023-01-29 16:09:35

『壹』 Win7旗艦版系統下使用qq截圖功能實現快速截圖的技巧

1、首先要打開並運行QQ程序,接著在鍵盤上按下crtl+alt+A組合快捷鍵自動調出QQ截圖功能;
2、然後拖動滑鼠,選擇你需要截圖的地方,選擇好之後可以右鍵選擇“完成”或者“保存”,或者直接點擊截圖下方的工具欄進行保存,完成的功能作用就是復制到剪貼板中,在需要的地方粘貼就可以,如果選擇保存就是將其保存到電腦的路徑中。
3、如果用戶對截出來的圖片不滿意的話,可以滑鼠右鍵退出截圖,然後再重新截圖就可以了。

『貳』 c#如何實現類似qq一樣的截圖功能

按快捷鍵後,先把整個屏幕截下來,然後顯示在form1上,form1是一個沒有邊框的窗體,之後最大化顯示form1,開始滑鼠拖坐標,截取坐標內的圖片,保存,

補充:
4年前用vb寫的:

Option Explicit

Private Declare Sub keybd_event Lib "user32" (ByVal bVk As Byte, ByVal bScan As Byte, ByVal dwFlags As Long, ByVal dwExtraInfo As Long)
Const theScreen = 0
Const theForm = 1

Private Sub Form_Load()
XPForm1.Make
Load Form2
End Sub

Private Sub Form_Unload(Cancel As Integer)
Unload Form2
Unload Me
End Sub

Private Sub HScroll1_Change()
If Picture1.Width > Picture2.Width Then
Picture1.Left = -((Picture1.Width - Picture2.Width) / 100) * HScroll1.Value
End If
End Sub

Private Sub MGButton1_Click()
If Option1.Value = True Then
If Check1.Value = 1 Then
Me.Hide
End If
Call Delay
Call keybd_event(vbKeySnapshot, theScreen, 0, 0)
Call Delay
Form2.Picture = Clipboard.GetData(vbCFBitmap)
Form2.Shape1.Height = 0
Form2.Shape1.Width = 0
Form2.Picture2.Visible = False
Form2.Picture3.Visible = False
Form2.Picture4.Visible = False
Form2.Show 1, Me
ElseIf Option2.Value = True Then
If Check1.Value = 1 Then
Me.Hide
End If
Call Delay
Call keybd_event(vbKeySnapshot, theScreen, 0, 0)
Call Delay
Picture1.Cls
Picture1.Picture = Clipboard.GetData(vbCFBitmap)
Me.Show
ElseIf Option3.Value = True Then
If Check1.Value = 1 Then
Me.Hide
End If
Call Delay
Call keybd_event(vbKeySnapshot, theForm, 0, 0)
Call Delay
Picture1.Cls
Picture1.Picture = Clipboard.GetData(vbCFBitmap)
Me.Show
Else
End If
End Sub

Private Sub Delay()
Dim i As Integer
For i = 0 To 1000
DoEvents
Next i
End Sub

Private Sub MGButton2_Click()
Picture1.Cls
Picture1.Picture = LoadPicture
End Sub

Private Sub MGButton3_Click()
CommonDialog1.DialogTitle = "保存"
CommonDialog1.FileName = ""
CommonDialog1.Filter = "點陣圖文件(*.BMP)|*.bmp|所有文件(*.*)|*.*"
CommonDialog1.FilterIndex = 0
CommonDialog1.ShowSave

If CommonDialog1.FileName <> "" Then
SavePicture Picture1.Image, CommonDialog1.FileName
End If
End Sub

Private Sub MGButton4_Click()
Clipboard.SetData Picture1.Image, vbCFBitmap
End Sub

Private Sub VScroll1_Change()
If Picture1.Height > Picture2.Height Then
Picture1.Top = -((Picture1.Height - Picture2.Height) / 100) * VScroll1.Value
End If
End Sub

『叄』 本人是用C#做了一個QQ程序...如果做一個截圖功能

比較長的代碼···
思路也比較明顯,你可以看看

using System;
using System.Drawing;
using System.Windows.Forms;

namespace Teboscreen
{

public partial class Form1 : Form
{
#region:::::::::::::::::::::::::::::::::::::::::::Form level declarations:::::::::::::::::::::::::::::::::::::::::::
public bool LeftButtonDown = false;
string ScreenPath;

public Point ClickPoint = new Point();
public Point ReleasePoint = new Point();
public Point LastPoint = new Point();
public Point CurrentPoint = new Point();

Graphics g;
Pen MyPen = new Pen(Color.Blue, 1);
Pen EraserPen = new Pen(Color.FromArgb(255, 255, 192), 1);

private Form m_InstanceRef = null;
public Form InstanceRef
{
get
{
return m_InstanceRef;
}
set
{
m_InstanceRef = value;
}
}

#endregion

#region:::::::::::::::::::::::::::::::::::::::::::Mouse Event Handlers & Drawing Initialization:::::::::::::::::::::::::::::::::::::::::::
public Form1()
{

InitializeComponent();
this.MouseDown += new MouseEventHandler(mouse_Click);
this.MouseUp += new MouseEventHandler(mouse_Up);
this.MouseMove += new MouseEventHandler(mouse_Move);
MyPen.DashStyle = System.Drawing.Drawing2D.DashStyle.Dot;
g = this.CreateGraphics();

}
#endregion

#region:::::::::::::::::::::::::::::::::::::::::::Exit Button:::::::::::::::::::::::::::::::::::::::::::
private void button1_Click(object sender, EventArgs e)
{
Close();
}
#endregion
#region:::::::::::::::::::::::::::::::::::::::::::Mouse Buttons:::::::::::::::::::::::::::::::::::::::::::
private void mouse_Click(object sender, MouseEventArgs e)
{
g.Clear(Color.FromArgb(255, 255, 192));
LeftButtonDown = true;
ClickPoint = new Point(System.Windows.Forms.Control.MousePosition.X, System.Windows.Forms.Control.MousePosition.Y);
}

private void mouse_Up(object sender, MouseEventArgs e)
{
LeftButtonDown = false;
ReleasePoint = new Point(System.Windows.Forms.Control.MousePosition.X, System.Windows.Forms.Control.MousePosition.Y);
saveFileDialog1.DefaultExt = "bmp";
saveFileDialog1.Filter = "bmp files (*.bmp)|*.bmp";
saveFileDialog1.Title = "Save screenshot to...";
saveFileDialog1.ShowDialog();
ScreenPath = saveFileDialog1.FileName;

if ("" != ScreenPath)
{
SaveScreen();
}

this.Hide();
ControlPanel controlpanel = new ControlPanel();
controlpanel.InstanceRef = this;
controlpanel.Show();

}
#endregion

#region:::::::::::::::::::::::::::::::::::::::::::Drawing the rectangular selection window:::::::::::::::::::::::::::::::::::::::::::
private void mouse_Move(object sender, MouseEventArgs e)
{

//Resize (actually delete then re-draw) the rectangle if the left mouse button is held down
if (LeftButtonDown)
{

//Erase the previous rectangle
g.DrawRectangle(EraserPen, ClickPoint.X, ClickPoint.Y, LastPoint.X - ClickPoint.X, LastPoint.Y - ClickPoint.Y);

//Save the current location of the cursor for erasing the rectangle on next move
LastPoint = new Point(Cursor.Position.X, Cursor.Position.Y);

//Draw a new rectangle
g.DrawRectangle(MyPen, ClickPoint.X, ClickPoint.Y, Cursor.Position.X - ClickPoint.X, Cursor.Position.Y - ClickPoint.Y);
//Save the current cursor position, in case the button is released, for ScreenShot.CaptureImage
CurrentPoint = new Point(Cursor.Position.X, Cursor.Position.Y);

}

}
#endregion

#region:::::::::::::::::::::::::::::::::::::::::::SaveScreen:::::::::::::::::::::::::::::::::::::::::::
private void SaveScreen()
{

Point StartPoint = new Point(ClickPoint.X, ClickPoint.Y);
Rectangle bounds = new Rectangle(ClickPoint.X, ClickPoint.Y, CurrentPoint.X - ClickPoint.X, CurrentPoint.Y - ClickPoint.Y);
ScreenShot.CaptureImage(StartPoint, Point.Empty, bounds, ScreenPath);

}
#endregion

}
}

這個是ControlPanel代碼
using System;
using System.Drawing;
using System.Windows.Forms;

namespace Teboscreen
{

public partial class ControlPanel : Form
{

string ScreenPath;

private Form m_InstanceRef = null;
public Form InstanceRef
{
get
{
return m_InstanceRef;
}
set
{
m_InstanceRef = value;
}
}

public ControlPanel()
{
InitializeComponent();
}

private void bttCaptureArea_Click(object sender, EventArgs e)
{
this.Hide();
Form1 form1 = new Form1();
form1.InstanceRef = this;
form1.Show();
}

private void bttExit_Click(object sender, EventArgs e)
{
Application.Exit();
}

private void bttCaptureScreen_Click(object sender, EventArgs e)
{

saveFileDialog1.DefaultExt = "bmp";
saveFileDialog1.Filter = "bmp files (*.bmp)|*.bmp";
saveFileDialog1.Title = "Save screenshot to...";
saveFileDialog1.ShowDialog();
ScreenPath = saveFileDialog1.FileName;

//Conceal this form while the screen capture takes place
this.WindowState = System.Windows.Forms.FormWindowState.Minimized;
this.TopMost = false;

//Allow 250 milliseconds for the screen to repaint itself (we don't want to include this form in the capture)
System.Threading.Thread.Sleep(250);

Rectangle bounds = Screen.GetBounds(Screen.GetBounds(Point.Empty));
ScreenShot.CaptureImage(Point.Empty, Point.Empty, bounds, ScreenPath);

//The screen has been captured and saved to a file so bring this form back into the foreground
this.WindowState = System.Windows.Forms.FormWindowState.Normal;
this.TopMost = true;

}

}
}

ScreenShot代碼
using System;
using System.Drawing;
using System.Drawing.Imaging;

namespace Teboscreen
{
class ScreenShot
{
public static void CaptureImage(Point SourcePoint, Point DestinationPoint, Rectangle SelectionRectangle, string FilePath)
{
using (Bitmap bitmap = new Bitmap(SelectionRectangle.Width, SelectionRectangle.Height))
{
using (Graphics g = Graphics.FromImage(bitmap))
{
g.CopyFromScreen(SourcePoint, DestinationPoint, SelectionRectangle.Size);
}
bitmap.Save(FilePath, ImageFormat.Bmp);
}
}
}
}

『肆』 哪裡有java寫的類似QQ截圖工具的源代碼

不能立即給你提供源碼 但是可以教給你怎麼實現。
首先 你要截屏 肯定專要在屬於用滑鼠圈定屬一個區域來截取這個區域。

你可以這樣:
先截取當前屏幕的滿屏圖片:new robot().createScreenCapture(r) 這個是截屏代碼 r是Rectangle類型 代表要截取的區域。

然後用 JDialog 做一個無控制條的窗口,大小設置成滿屏,把截取的這個滿屏的圖片貼到這個 JDiaglog 里

然後做一下滑鼠圈定區域,這個很簡單 不詳細說了, 最後對你圈定的這個區域再做一次截屏,這個不就是你要的截圖了。,。 最後別忘了 截屏完畢後 關閉JDialog

你要是覺得這樣做麻煩,也沒別的辦法。 反正我很明白 QQ的截屏也是這樣做的

『伍』 像QQ的截圖功能 隨意截屏這種功能 是用什麼語言寫的啊javac

1、截圖是把電腦上所顯示的部分截取下來形成圖片。下載圖片是把網頁上的圖片保存版到本機。2、電腦截圖最簡權單的就是按PrtScr(printScreen)鍵,一般在方向鍵上面的那個鍵盤區的左上角。然後在電腦的程序、附件、畫圖軟體中粘貼就可以保存下來。當然也可以粘貼到其他軟體中。比如photoshop、word、 等等。3、 截圖可以在聊天過程中選擇聊天窗口下面的一個小顯示器加小剪刀圖標,然後拖動滑鼠出現小框選擇要截取的屏幕部分。之後雙擊滑鼠就可以把要截取的部分粘貼到聊天窗口裡。還有一種方法是 軟體開著,但是不管有沒有聊天窗口可以按CTRL+ALT+A鍵,同樣可以截取,截取之後的內容想用的時候在任何可以粘貼的軟體中按粘貼即可。或者按快捷鍵CTRL+V也可以實現粘貼。兩種方法在想取消截屏時按滑鼠右鍵都可以取消。4、如果只要一小部分就可以用 來截取,方法上面說過了。或者只要一個軟體或網頁的窗口可以按ALT+PrtScr鍵就可以只截取軟體窗口了。

『陸』 qq截圖怎麼操作

以電腦為例,qq截圖的操作步驟是:
1、進入到QQ頁面,在消息下方,找到要截圖的好友的聊天頁面,在聊天界面里,點擊功能欄中的【小剪刀】圖標。
2、最後按住滑鼠左鍵,移動滑鼠,拖選好要截圖的位置,托選好之後,松開滑鼠,點擊【完成】命令即可。
QQ空間是目前中國最大的互聯網綜合服務提供商之一,也是中國服務用戶最多的互聯網企業之一。成立10多年以來,騰訊一直秉承「一切以用戶價值為依歸」的經營理念,始終處於穩健發展的狀態。2004年6月16日,在QQ空間上可以書寫日誌、寫說說、上傳用戶個人的圖片、聽音樂等功能。除此之外,用戶還可以根據個人的喜愛設定空間的背景、小掛件等,從而使空間有自己的特色。
截至2016年底,QQ空間月活躍賬戶數達到6.52億、QQ空間智能終端月活躍賬戶數達到5.96億。騰訊QQ空間已禁止使用自定義代碼(QQ空間模塊,QQ空間留言代碼除外),具體禁止日期無從考證,開通日期亦無預期。所有網路上流傳的(QQ空間模塊,QQ空間留言代碼除外)都已過期。

『柒』 asp.net 如何實現把qq截圖粘貼的textbox中

不現實也不能實現的(當然在未來HTML6、7。。。的版本中可能會實現)。
如果是WinForm程序的話是可以實現的。
因為QQ截圖是保存在系統的截切板中的,而ASP.NET所生成的最終將會是一個HTML頁面。
而HTML頁面裡面只能運行js代碼(插入flash、silverlight、activeX等其他插件不算)。
又因為js是運行在瀏覽器端的,所以有安全限制,故意讓js代碼沒許可權訪問到截切板的。
所以,js不能訪問到剪切板,故而不能實現你所說的需求。

『捌』 QQ截圖的灰屏效果。要用C#語言實現,那位高手會啊,要代碼哦。

造一個沒有任何菜單框的無邊框的空白的窗體,並且一開始就最大化,不透明度為30%(這個可以自己調,不透明度越高,就越難透過後面的東西,顏色就越深。) ,背景色為黑色的窗體(ControlBox=false Text=

『玖』 vb模擬QQ 截圖

下面的代碼是我很欣賞的編程牛人CBM666的,你看下就應該能明白意思了,需要的haunted自己修改一下,我運行過了可以運行成功,不會截到其它窗體只是列印當前窗體
友情提示:你點下列印鍵的時候沒有提示會直接列印出窗口內容來,沒有確定取消的按鈕的,當初我在公司試的時候隨便貼了個很爛的圖就給打出來了,還被人笑了。。。

'添加 Picture1 Picture2 各別放一張圖片 窗體也可加圖片, 只是測試用罷了.
,Text1 隨便打一些內容,(只是測試用)
'再隨便加一個Picture3 用來保存圖片
'Command1 抓圖存圖 Command2 列印

'本代碼是將窗體內所有的控制項與窗體一起保存到Picture3再列印出來.

Option Explicit
Private Declare Sub keybd_event Lib "user32" (ByVal bVk As Byte, ByVal bScan As Byte, ByVal dwFlags As Long, ByVal dwExtraInfo As Long)
Const theScreen = 0 '整個Screen
Const theForm = 1 '當前活動界面
Private Sub Form_Load()
Command1.Caption = "抓取窗體"
Command2.Caption = "打 印"
Picture3.Move Screen.Width
Picture3.AutoRedraw = True
Picture3.BorderStyle = 0
Me.AutoRedraw = False
Clipboard.Clear
End Sub

Private Sub Command1_Click()
Me.Refresh
Picture3.Picture = LoadPicture()
Picture3.Width = Me.Width
Picture3.Height = Me.Height
Call keybd_event(vbKeySnapshot, 1, 0, 0)
DoEvents
Picture3.Picture = Clipboard.GetData(vbCFBitmap)
Set Picture3.Picture = Picture3.Image '此時才真正顯示Picture
'SavePicture Picture3.Image, "c:\kkkw.bmp"
End Sub

Private Sub Command2_Click()
Printer.PaintPicture Picture3.Picture, 0, 0, Picture3.Width, Picture3.Height
Printer.EndDoc
End Sub

有空你搜索下CBM666的代碼,絕對能給你很大收獲

閱讀全文

與qq截圖代碼實現相關的資料

熱點內容
測繪大數據處理 瀏覽:739
appstore禁用銀行卡 瀏覽:369
ios支持文件夾導入的看書軟體 瀏覽:657
微信轉賬5000元圖片 瀏覽:703
桂林萬象城電影院今日影訊 瀏覽:58
note4文件管理移植 瀏覽:682
那種在線觀看網址鏈 瀏覽:321
資料庫中性別用什麼字元 瀏覽:672
易捷文件加密軟體注冊碼 瀏覽:312
一部關於偵探下馬和綉花鞋的老電影 瀏覽:19
山茶花之戀演員 瀏覽:750
周星馳全部電影在線免費觀看 瀏覽:613
vk網路中是什麼意思 瀏覽:489
win10UWP文件加密軟體 瀏覽:187
js怎麼判斷周六日 瀏覽:674
寄文件到香港多少運費 瀏覽:402
svn回到之前版本 瀏覽:342
!30e731Fzue! 瀏覽:697
重生山西抗戰軍閥 瀏覽:439
如下程序的輸出結果是 瀏覽:191

友情鏈接