国产av日韩一区二区三区精品,成人性爱视频在线观看,国产,欧美,日韩,一区,www.成色av久久成人,2222eeee成人天堂

首頁(yè) 微信小程序 微信開(kāi)發(fā) iOS開(kāi)發(fā)之微信聊天頁(yè)面實(shí)現(xiàn)

iOS開(kāi)發(fā)之微信聊天頁(yè)面實(shí)現(xiàn)

Feb 15, 2017 am 11:00 AM
IOS ui

  聊天界面的效果圖如下:在下面的聊天界面中中用到了3類cell,一類是顯示文字和表情的,一類是顯示錄音的,一類是顯示圖片的。當(dāng)點(diǎn)擊圖片時(shí)會(huì)跳轉(zhuǎn)到另一個(gè)Controller中來(lái)進(jìn)行圖片顯示,在圖片顯示頁(yè)面中添加了一個(gè)捏合的手勢(shì)。點(diǎn)擊播放按鈕,會(huì)播放錄制的音頻,cell的大學(xué)會(huì)根據(jù)內(nèi)容的多少來(lái)調(diào)整,而cell中textView的高度是通過(guò)約束來(lái)設(shè)置的。

iOS開(kāi)發(fā)之微信聊天頁(yè)面實(shí)現(xiàn)

  一,定義我們要用的cell,代碼如下:

    1,顯示表情和text的cell,代碼如下,需要根據(jù)NSMutableAttributedString求出bound,然后改變cell上的ImageView和TextView的寬度的約束值,動(dòng)態(tài)的調(diào)整氣泡的大小,具體代碼如下:

#import "TextCell.h"

@interface TextCell()

@property (strong, nonatomic) IBOutlet UIImageView *headImageView;
@property (strong, nonatomic) IBOutlet UIImageView *chatBgImageView;
@property (strong, nonatomic) IBOutlet UITextView *chatTextView;
@property (strong, nonatomic) IBOutlet NSLayoutConstraint *chatBgImageWidthConstraint;
@property (strong, nonatomic) IBOutlet NSLayoutConstraint *chatTextWidthConstaint;
@property (strong, nonatomic) NSMutableAttributedString *attrString;

@end

@implementation TextCell

-(void)setCellValue:(NSMutableAttributedString *)str
{
    //移除約束
    [self removeConstraint:_chatBgImageWidthConstraint];
    [self removeConstraint:_chatTextWidthConstaint];
    
    self.attrString = str;
    NSLog(@"%@",self.attrString);
    
    //由text計(jì)算出text的寬高
      CGRect bound = [self.attrString boundingRectWithSize:CGSizeMake(150, 1000) options:NSStringDrawingUsesLineFragmentOrigin context:nil];
   
    //根據(jù)text的寬高來(lái)重新設(shè)置新的約束
    //背景的寬
    NSString *widthImageString;
    NSArray *tempArray;
    
    widthImageString = [NSString stringWithFormat:@"H:[_chatBgImageView(%f)]", bound.size.width+45];
    tempArray = [NSLayoutConstraint constraintsWithVisualFormat:widthImageString options:0 metrics:0 views:NSDictionaryOfVariableBindings(_chatBgImageView)];
    _chatBgImageWidthConstraint = tempArray[0];
    [self addConstraint:self.chatBgImageWidthConstraint];
    
    widthImageString = [NSString stringWithFormat:@"H:[_chatTextView(%f)]", bound.size.width+20];
    tempArray = [NSLayoutConstraint constraintsWithVisualFormat:widthImageString options:0 metrics:0 views:NSDictionaryOfVariableBindings(_chatTextView)];
    _chatBgImageWidthConstraint = tempArray[0];
    [self addConstraint:self.chatBgImageWidthConstraint];
    
    //設(shè)置圖片
    UIImage *image = [UIImage imageNamed:@"chatfrom_bg_normal.png"];
    image = [image resizableImageWithCapInsets:(UIEdgeInsetsMake(image.size.height * 0.6, image.size.width * 0.4, image.size.height * 0.3, image.size.width * 0.4))];
    
    //image = [image stretchableImageWithLeftCapWidth:image.size.width * 0.5 topCapHeight:image.size.height * 0.5];
    
    
    
    [self.chatBgImageView setImage:image];
    
    self.chatTextView.attributedText = str;
    
    
}

@end

 2.顯示圖片的cell,通過(guò)block回調(diào)把圖片傳到Controller中,用于放大圖片使用。

#import "MyImageCell.h"

@interface MyImageCell()
@property (strong, nonatomic) IBOutlet UIImageView *bgImageView;
@property (strong, nonatomic) IBOutlet UIButton *imageButton;
@property (strong, nonatomic) ButtonImageBlock imageBlock;
@property (strong, nonatomic) UIImage *buttonImage;

@end

@implementation MyImageCell

-(void)setCellValue:(UIImage *)sendImage
{
    self.buttonImage = sendImage;
    UIImage *image = [UIImage imageNamed:@"chatto_bg_normal.png"];
    image = [image resizableImageWithCapInsets:(UIEdgeInsetsMake(image.size.height * 0.6, image.size.width * 0.4, image.size.height * 0.3, image.size.width * 0.4))];
    [self.bgImageView setImage:image];
    [self.imageButton setImage:sendImage forState:UIControlStateNormal];

}

-(void)setButtonImageBlock:(ButtonImageBlock)block
{
    self.imageBlock = block;
}

- (IBAction)tapImageButton:(id)sender {
    self.imageBlock(self.buttonImage);
}

@end

 3.顯示錄音的cell,點(diǎn)擊cell上的button,播放對(duì)應(yīng)的錄音,代碼如下:

#import "VoiceCellTableViewCell.h"

@interface VoiceCellTableViewCell()

@property (strong, nonatomic) NSURL *playURL;
@property (strong, nonatomic) AVAudioPlayer *audioPlayer;

@end

@implementation VoiceCellTableViewCell

-(void)setCellValue:(NSDictionary *)dic
{
    _playURL = dic[@"body"][@"content"];
}

- (IBAction)tapVoiceButton:(id)sender {
    
    
    NSError *error = nil;
    AVAudioPlayer *player = [[AVAudioPlayer alloc]initWithContentsOfURL:_playURL error:&error];
    if (error) {
        NSLog(@"播放錯(cuò)誤:%@",[error description]);
    }
    self.audioPlayer = player;
    [self.audioPlayer play];
}
@end

二,cell搞定后要實(shí)現(xiàn)我們的ChatController部分    

ChatController.m中的延展和枚舉代碼如下:

//枚舉Cell類型
typedef enum : NSUInteger {
    SendText,
    SendVoice,
    SendImage
} MySendContentType;


//枚舉用戶類型
typedef enum : NSUInteger {
    MySelf,
    MyFriend
} UserType;

@interface ChatViewController ()

//工具欄
@property (nonatomic,strong) ToolView *toolView;

//音量圖片
@property (strong, nonatomic) UIImageView *volumeImageView;

//工具欄的高約束,用于當(dāng)輸入文字過(guò)多時(shí)改變工具欄的約束
@property (strong, nonatomic) NSLayoutConstraint *tooViewConstraintHeight;

//存放所有的cell中的內(nèi)容
@property (strong, nonatomic) NSMutableArray *dataSource;

//storyBoard上的控件
@property (strong, nonatomic) IBOutlet UITableView *myTableView;

//用戶類型
@property (assign, nonatomic) UserType userType;

//從相冊(cè)獲取圖片
@property (strong, nonatomic) UIImagePickerController *imagePiceker;

@end

實(shí)現(xiàn)工具欄中的回調(diào)的代碼如下,通過(guò)Block,工具欄和ViewController交互

//實(shí)現(xiàn)工具欄的回調(diào)
-(void)setToolViewBlock
{
    __weak __block ChatViewController *copy_self = self;
    //通過(guò)block回調(diào)接收到toolView中的text
    [self.toolView setMyTextBlock:^(NSString *myText) {
        NSLog(@"%@",myText);
        
        [copy_self sendMessage:SendText Content:myText];
    }];
    
    
    //回調(diào)輸入框的contentSize,改變工具欄的高度
    [self.toolView setContentSizeBlock:^(CGSize contentSize) {
         [copy_self updateHeight:contentSize];
    }];
    
    
    //獲取錄音聲量,用于聲音音量的提示
    [self.toolView setAudioVolumeBlock:^(CGFloat volume) {
        
        copy_self.volumeImageView.hidden = NO;
        int index = (int)(volume*100)%6+1;
        [copy_self.volumeImageView setImage:[UIImage imageNamed:[NSString stringWithFormat:@"record_animate_%02d.png",index]]];
    }];
    
    //獲取錄音地址(用于錄音播放方法)
    [self.toolView setAudioURLBlock:^(NSURL *audioURL) {
        copy_self.volumeImageView.hidden = YES;
        
        [copy_self sendMessage:SendVoice Content:audioURL];
    }];
    
    //錄音取消(錄音取消后,把音量圖片進(jìn)行隱藏)
    [self.toolView setCancelRecordBlock:^(int flag) {
        if (flag == 1) {
            copy_self.volumeImageView.hidden = YES;
        }
    }];
    
    
    //擴(kuò)展功能回調(diào)
    [self.toolView setExtendFunctionBlock:^(int buttonTag) {
        switch (buttonTag) {
            case 1:
                //從相冊(cè)獲取
                [copy_self presentViewController:copy_self.imagePiceker animated:YES completion:^{
                    
                }];
                break;
            case 2:
                //拍照
                break;
                
            default:
                break;
        }
    }];
}

把聊天工具欄中返回的內(nèi)容顯示在tableView中,代碼如下:

//發(fā)送消息
-(void)sendMessage:(MySendContentType) sendType Content:(id)content
{
    
    //把收到的url封裝成字典
    UserType userType = self.userType;
    
    NSMutableDictionary *tempDic = [[NSMutableDictionary alloc] initWithCapacity:2];
    [tempDic setValue:@(userType) forKey:@"userType"];
    
    NSDictionary *bodyDic = @{@"type":@(sendType),
                              @"content":content};
    [tempDic setValue:bodyDic forKey:@"body"];
    [self.dataSource addObject:tempDic];
    
    //重載tableView
    [self.myTableView  reloadData];
    
    NSIndexPath *indexPath = [NSIndexPath indexPathForRow:self.dataSource.count-1 inSection:0];
    
    [self.myTableView scrollToRowAtIndexPath:indexPath atScrollPosition:UITableViewScrollPositionBottom animated:YES];
    
 
}

根據(jù)ToolView中回調(diào)接口,獲取工具欄中textView的ContentSize,通過(guò)ContentSize來(lái)調(diào)整ToolView的高度約束,代碼如下:

//更新toolView的高度約束
-(void)updateHeight:(CGSize)contentSize
{
    float height = contentSize.height + 18;
    if (height <= 80) {
        [self.view removeConstraint:self.tooViewConstraintHeight];
        
        NSString *string = [NSString stringWithFormat:@"V:[_toolView(%f)]", height];
        
        NSArray * tooViewConstraintV = [NSLayoutConstraint constraintsWithVisualFormat:string options:0 metrics:0 views:NSDictionaryOfVariableBindings(_toolView)];
        self.tooViewConstraintHeight = tooViewConstraintV[0];
        [self.view addConstraint:self.tooViewConstraintHeight];
    }
}

從本地獲取圖片,并顯示在相應(yīng)的Cell上,代碼如下:

//獲取圖片后要做的方法
-(void)imagePickerController:(UIImagePickerController *)picker didFinishPickingMediaWithInfo:(NSDictionary *)info
{
    UIImage *pickerImage = info[UIImagePickerControllerEditedImage];
    
    //發(fā)送圖片
    [self sendMessage:SendImage Content:pickerImage];
    
    [self dismissViewControllerAnimated:YES completion:^{}];
    
}

-(void)imagePickerControllerDidCancel:(UIImagePickerController *)picker
{
    //在ImagePickerView中點(diǎn)擊取消時(shí)回到原來(lái)的界面
    [self dismissViewControllerAnimated:YES completion:^{}];
}

把NSString 轉(zhuǎn)換成NSMutableAttributeString,用于顯示表情,代碼如下:

//顯示表情,用屬性字符串顯示表情
-(NSMutableAttributedString *)showFace:(NSString *)str
{
    //加載plist文件中的數(shù)據(jù)
    NSBundle *bundle = [NSBundle mainBundle];
    //尋找資源的路徑
    NSString *path = [bundle pathForResource:@"emoticons" ofType:@"plist"];
    //獲取plist中的數(shù)據(jù)
    NSArray *face = [[NSArray alloc] initWithContentsOfFile:path];
    
    //創(chuàng)建一個(gè)可變的屬性字符串
    
    NSMutableAttributedString *attributeString = [[NSMutableAttributedString alloc] initWithString:str];
    
    UIFont *baseFont = [UIFont systemFontOfSize:17];
    [attributeString addAttribute:NSFontAttributeName value:baseFont
                       range:NSMakeRange(0, str.length)];
    
    //正則匹配要替換的文字的范圍
    //正則表達(dá)式
    NSString * pattern = @"\\[[a-zA-Z0-9\\u4e00-\\u9fa5]+\\]";
    NSError *error = nil;
    NSRegularExpression * re = [NSRegularExpression regularExpressionWithPattern:pattern options:NSRegularExpressionCaseInsensitive error:&error];
    
    if (!re) {
        NSLog(@"%@", [error localizedDescription]);
    }
    
    //通過(guò)正則表達(dá)式來(lái)匹配字符串
    NSArray *resultArray = [re matchesInString:str options:0 range:NSMakeRange(0, str.length)];
    
    
    //用來(lái)存放字典,字典中存儲(chǔ)的是圖片和圖片對(duì)應(yīng)的位置
    NSMutableArray *imageArray = [NSMutableArray arrayWithCapacity:resultArray.count];
    
    //根據(jù)匹配范圍來(lái)用圖片進(jìn)行相應(yīng)的替換
    for(NSTextCheckingResult *match in resultArray) {
        //獲取數(shù)組元素中得到range
        NSRange range = [match range];
        
        //獲取原字符串中對(duì)應(yīng)的值
        NSString *subStr = [str substringWithRange:range];
        
        for (int i = 0; i < face.count; i ++)
        {
            if ([face[i][@"chs"] isEqualToString:subStr])
            {
                
                //face[i][@"gif"]就是我們要加載的圖片
                //新建文字附件來(lái)存放我們的圖片
                NSTextAttachment *textAttachment = [[NSTextAttachment alloc] init];
                
                //給附件添加圖片
                textAttachment.image = [UIImage imageNamed:face[i][@"png"]];
                
                //把附件轉(zhuǎn)換成可變字符串,用于替換掉源字符串中的表情文字
                NSAttributedString *imageStr = [NSAttributedString attributedStringWithAttachment:textAttachment];
                
                //把圖片和圖片對(duì)應(yīng)的位置存入字典中
                NSMutableDictionary *imageDic = [NSMutableDictionary dictionaryWithCapacity:2];
                [imageDic setObject:imageStr forKey:@"image"];
                [imageDic setObject:[NSValue valueWithRange:range] forKey:@"range"];
                
                //把字典存入數(shù)組中
                [imageArray addObject:imageDic];
                
            }
        }
    }
    
    //從后往前替換
    for (int i = imageArray.count -1; i >= 0; i--)
    {
        NSRange range;
        [imageArray[i][@"range"] getValue:&range];
        //進(jìn)行替換
        [attributeString replaceCharactersInRange:range withAttributedString:imageArray[i][@"image"]];
        
    }
    
    return  attributeString;
}

根據(jù)Cell顯示內(nèi)容來(lái)調(diào)整Cell的高度,代碼如下:

//調(diào)整cell的高度
-(float)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath
{
    
    //根據(jù)文字計(jì)算cell的高度
    if ([self.dataSource[indexPath.row][@"body"][@"type"] isEqualToNumber:@(SendText)]) {
        NSMutableAttributedString *contentText = [self showFace:self.dataSource[indexPath.row][@"body"][@"content"]];
        
        CGRect textBound = [contentText boundingRectWithSize:CGSizeMake(150, 1000) options:NSStringDrawingUsesLineFragmentOrigin context:nil];
        
        float height = textBound.size.height + 40;
        return height;
    }
    if ([self.dataSource[indexPath.row][@"body"][@"type"] isEqualToNumber:@(SendVoice)])
    {
        return 73;
    }
    
    if ([self.dataSource[indexPath.row][@"body"][@"type"] isEqualToNumber:@(SendImage)])
    {
        return 125;
    }
    
    return 100;
 }

根據(jù)cell內(nèi)容和用戶類型,來(lái)選擇Cell,代碼如下:

//設(shè)置cell
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
{
    //根據(jù)類型選cell
    MySendContentType contentType = [self.dataSource[indexPath.row][@"body"][@"type"] integerValue];
    
    
    if ([self.dataSource[indexPath.row][@"userType"]  isEqual: @(MyFriend)]) {
        switch (contentType) {
            case SendText:
            {
                TextCell *cell = [tableView dequeueReusableCellWithIdentifier:@"textCell" forIndexPath:indexPath];
                NSMutableAttributedString *contentText = [self showFace:self.dataSource[indexPath.row][@"body"][@"content"]];
                [cell setCellValue:contentText];
                return cell;
            }
                break;
                
            case SendImage:
            {
                heImageCell *cell = [tableView dequeueReusableCellWithIdentifier:@"heImageCell" forIndexPath:indexPath];
                [cell setCellValue:self.dataSource[indexPath.row][@"body"][@"content"]];
                
                
                __weak __block ChatViewController *copy_self = self;
                
                //傳出cell中的圖片
                [cell setButtonImageBlock:^(UIImage *image) {
                    [copy_self displaySendImage:image];
                }];
                return cell;
            }
                break;
                
            case SendVoice:
            {
                VoiceCellTableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:@"heVoiceCell" forIndexPath:indexPath];
                [cell setCellValue:self.dataSource[indexPath.row]];
                return cell;
            }

                break;
                
            default:
                break;
        }

    }
        

    if ([self.dataSource[indexPath.row][@"userType"]  isEqual: @(MySelf)]) {
    
        switch (contentType) {
            case SendText:
            {
                TextCell *cell = [tableView dequeueReusableCellWithIdentifier:@"myselfTextCell" forIndexPath:indexPath];
                NSMutableAttributedString *contentText = [self showFace:self.dataSource[indexPath.row][@"body"][@"content"]];
                [cell setCellValue:contentText];
                return cell;
            }
            break;
            
            case SendImage:
            {
                MyImageCell *cell = [tableView dequeueReusableCellWithIdentifier:@"myImageCell" forIndexPath:indexPath];
                [cell setCellValue:self.dataSource[indexPath.row][@"body"][@"content"]];
                
                __weak __block ChatViewController *copy_self = self;
                
                //傳出cell中的圖片
                [cell setButtonImageBlock:^(UIImage *image) {
                    [copy_self displaySendImage:image];
                }];

                
                return cell;
            }
                break;
            
            case SendVoice:
            {
                VoiceCellTableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:@"myVoiceCell" forIndexPath:indexPath];
                [cell setCellValue:self.dataSource[indexPath.row]];
                return cell;
            }

                break;
                
            default:
                break;
        }
    }
    UITableViewCell *cell;
    return cell;
}

點(diǎn)擊發(fā)送的圖片來(lái)放大圖片代碼如下:

//發(fā)送圖片的放大
-(void) displaySendImage : (UIImage *)image
{
    //把照片傳到放大的controller中
    UIStoryboard *storyboard = [UIStoryboard storyboardWithName:@"Main" bundle:[NSBundle mainBundle]];
    
    ImageViewController *imageController = [storyboard instantiateViewControllerWithIdentifier:@"imageController"];
    [imageController setValue:image forKeyPath:@"image"];
    
   [self.navigationController pushViewController:imageController animated:YES];
    

}

根據(jù)鍵盤的高度來(lái)調(diào)整ToolView的位置,代碼如下:

//鍵盤出來(lái)的時(shí)候調(diào)整tooView的位置
-(void) keyChange:(NSNotification *) notify
{
    NSDictionary *dic = notify.userInfo;
    
    
    CGRect endKey = [dic[@"UIKeyboardFrameEndUserInfoKey"] CGRectValue];
    //坐標(biāo)系的轉(zhuǎn)換
    CGRect endKeySwap = [self.view convertRect:endKey fromView:self.view.window];
    //運(yùn)動(dòng)時(shí)間
    [UIView animateWithDuration:[dic[UIKeyboardAnimationDurationUserInfoKey] floatValue] animations:^{
        
        [UIView setAnimationCurve:[dic[UIKeyboardAnimationCurveUserInfoKey] doubleValue]];
        CGRect frame = self.view.frame;
        
        frame.size.height = endKeySwap.origin.y;
        
        self.view.frame = frame;
        [self.view layoutIfNeeded];
    }];
}

代碼有點(diǎn)多,不過(guò)在關(guān)鍵的部分都加有注釋,在圖片顯示View中通過(guò)捏合手勢(shì)來(lái)調(diào)整圖片的大小,代碼如下:

- (IBAction)tapPichGesture:(id)sender {
    UIPinchGestureRecognizer *gesture = sender;
    
    //手勢(shì)改變時(shí)
    if (gesture.state == UIGestureRecognizerStateChanged)
    {
        
        //捏合手勢(shì)中scale屬性記錄的縮放比例
        self.myImageView.transform = CGAffineTransformMakeScale(gesture.scale, gesture.scale);
    }
    
}

更多iOS開(kāi)發(fā)之微信聊天頁(yè)面實(shí)現(xiàn)?相關(guān)文章請(qǐng)關(guān)注PHP中文網(wǎng)!

本站聲明
本文內(nèi)容由網(wǎng)友自發(fā)貢獻(xiàn),版權(quán)歸原作者所有,本站不承擔(dān)相應(yīng)法律責(zé)任。如您發(fā)現(xiàn)有涉嫌抄襲侵權(quán)的內(nèi)容,請(qǐng)聯(lián)系admin@php.cn

熱AI工具

Undress AI Tool

Undress AI Tool

免費(fèi)脫衣服圖片

Undresser.AI Undress

Undresser.AI Undress

人工智能驅(qū)動(dòng)的應(yīng)用程序,用于創(chuàng)建逼真的裸體照片

AI Clothes Remover

AI Clothes Remover

用于從照片中去除衣服的在線人工智能工具。

Clothoff.io

Clothoff.io

AI脫衣機(jī)

Video Face Swap

Video Face Swap

使用我們完全免費(fèi)的人工智能換臉工具輕松在任何視頻中換臉!

熱工具

記事本++7.3.1

記事本++7.3.1

好用且免費(fèi)的代碼編輯器

SublimeText3漢化版

SublimeText3漢化版

中文版,非常好用

禪工作室 13.0.1

禪工作室 13.0.1

功能強(qiáng)大的PHP集成開(kāi)發(fā)環(huán)境

Dreamweaver CS6

Dreamweaver CS6

視覺(jué)化網(wǎng)頁(yè)開(kāi)發(fā)工具

SublimeText3 Mac版

SublimeText3 Mac版

神級(jí)代碼編輯軟件(SublimeText3)

熱門話題

Laravel 教程
1601
29
PHP教程
1502
276
艾爾登法環(huán)ui怎么一直顯示 艾爾登法環(huán)ui怎么一直顯示 Mar 11, 2024 pm 04:31 PM

在艾爾登法環(huán)中這款游戲的ui頁(yè)面在一段時(shí)間以后是會(huì)自動(dòng)進(jìn)行隱藏的,有很多玩家不知道ui怎么一直顯示,玩家可以在顯示以及聲音配置中選擇其中的量表顯示配置,點(diǎn)擊開(kāi)啟即可。艾爾登法環(huán)ui怎么一直顯示1、首先我們進(jìn)入主菜單后,點(diǎn)擊【系統(tǒng)配置】。2、在【顯示及聲音配置】界面,選擇其中的量表顯示配置。3、點(diǎn)擊開(kāi)啟即可完成。

Vue 中常見(jiàn)的 UI 組件庫(kù)有哪些? Vue 中常見(jiàn)的 UI 組件庫(kù)有哪些? Jun 11, 2023 am 11:47 AM

Vue是一款流行的JavaScript框架,它使用組件化的方式構(gòu)建Web應(yīng)用程序。在Vue生態(tài)系統(tǒng)中,有很多UI組件庫(kù)可以幫助您快速構(gòu)建漂亮的界面,并提供豐富的功能和交互效果。在本文中,我們將介紹一些常見(jiàn)的VueUI組件庫(kù)。ElementUIElementUI是一款由餓了么團(tuán)隊(duì)開(kāi)發(fā)的Vue組件庫(kù),它為開(kāi)發(fā)人員提供了一組優(yōu)雅,

兩位谷歌華人研究員發(fā)布首個(gè)純視覺(jué)「移動(dòng)UI理解」模型,四大任務(wù)刷新SOTA 兩位谷歌華人研究員發(fā)布首個(gè)純視覺(jué)「移動(dòng)UI理解」模型,四大任務(wù)刷新SOTA Apr 12, 2023 pm 04:40 PM

對(duì)AI來(lái)說(shuō),「玩手機(jī)」可不是一件易事,光是識(shí)別各種用戶界面(user interface, UI)就是一大難題:不光要識(shí)別出各個(gè)組件的類型,還要根據(jù)其使用的符號(hào)、位置來(lái)判斷組件的功能。對(duì)移動(dòng)設(shè)備UI的理解,能夠幫助實(shí)現(xiàn)各種人機(jī)交互任務(wù),比如UI自動(dòng)化等。之前的工作對(duì)移動(dòng)UI的建模通常依賴于屏幕的視圖層次信息,直接利用了UI的結(jié)構(gòu)數(shù)據(jù),并借此繞過(guò)了從屏幕像素開(kāi)始對(duì)組件進(jìn)行識(shí)別的難題。不過(guò)并不是所有的場(chǎng)景下都有可用的視圖層次,這種方法通常會(huì)因?yàn)閷?duì)象描述的缺失或結(jié)構(gòu)信息的錯(cuò)位而輸出錯(cuò)誤結(jié)果,所以盡管使

ui是什么意思的縮寫(xiě) ui是什么意思的縮寫(xiě) Mar 14, 2024 pm 03:20 PM

UI是“User Interface”的縮寫(xiě),主要用于描述軟件的人機(jī)交互、操作邏輯和界面美觀。UI設(shè)計(jì)的目的是讓軟件操作更簡(jiǎn)單舒適,充分體現(xiàn)其定位和特點(diǎn)。常見(jiàn)的UI設(shè)計(jì)分為實(shí)體UI和虛擬UI,其中虛擬UI廣泛應(yīng)用于互聯(lián)網(wǎng)領(lǐng)域。

探索最受歡迎的jQuery移動(dòng)UI框架 探索最受歡迎的jQuery移動(dòng)UI框架 Feb 27, 2024 pm 12:03 PM

jQuery移動(dòng)UI框架是一種用于開(kāi)發(fā)移動(dòng)應(yīng)用程序的工具,它提供了豐富的界面組件和交互效果,使開(kāi)發(fā)者能夠快速構(gòu)建優(yōu)秀的移動(dòng)用戶界面。在這篇文章中,我們將探索一些最受歡迎的jQuery移動(dòng)UI框架,并提供具體的代碼示例來(lái)幫助讀者更好地了解和使用這些框架。1.jQueryMobilejQueryMobile是一個(gè)基于HTML5和CSS3的開(kāi)源移動(dòng)UI框架,

Android 15 Beta 4 全面測(cè)試完成 穩(wěn)定版發(fā)布進(jìn)入倒計(jì)時(shí) Android 15 Beta 4 全面測(cè)試完成 穩(wěn)定版發(fā)布進(jìn)入倒計(jì)時(shí) Jul 29, 2024 pm 07:57 PM

日前,谷歌正式向符合條件的Pixel智能手機(jī)和平板電腦用戶推送了Android15Beta4更新,這標(biāo)志著Android15操作系統(tǒng)已邁入平臺(tái)穩(wěn)定階段,預(yù)示著其穩(wěn)定版將在接下來(lái)的幾天內(nèi)正式與全球用戶見(jiàn)面。同時(shí),這一進(jìn)展也為三星電子的Galaxy設(shè)備系列加速其OneUI7.0版本的開(kāi)發(fā)進(jìn)程注入了新的活力。1.[Android15Beta4推廣三星OneUI7.0穩(wěn)定構(gòu)建](https://www.cnbeta.com/articles/tech/1427022.htm)隨著Android15Bet

ui是什么意思 ui是什么意思 Mar 14, 2024 pm 03:09 PM

UI,全稱用戶界面,指的是軟件中人機(jī)交互、操作邏輯和界面美觀的設(shè)計(jì)。它分為實(shí)體UI和虛擬UI,其中虛擬UI廣泛應(yīng)用于移動(dòng)互聯(lián)網(wǎng)。好的UI設(shè)計(jì)不僅能讓軟件外觀有品位,更重要的是讓軟件操作變得舒適簡(jiǎn)易,充分體現(xiàn)軟件的定位和特點(diǎn)。

ux與ui設(shè)計(jì)的區(qū)別是什么 ux與ui設(shè)計(jì)的區(qū)別是什么 Sep 27, 2022 pm 03:52 PM

ux與ui設(shè)計(jì)的區(qū)別:1、UX讓界面更好用,UI讓界面更好看;2、UX讓用戶實(shí)現(xiàn)目標(biāo),UI讓界面提升品牌感;3、UX核心目標(biāo)引導(dǎo)用戶完成任務(wù),UI不是;4、UI和UX的交付成果不一樣,UX的輸出包括UX體驗(yàn)報(bào)告、功能定義、功能規(guī)劃、項(xiàng)目進(jìn)度等,而UI交付的包括視覺(jué)和交互、視覺(jué)設(shè)計(jì)、品牌設(shè)計(jì)、動(dòng)效設(shè)計(jì)、組件設(shè)計(jì)和設(shè)計(jì)語(yǔ)言等等。

See all articles