Time of Update: 2016-04-11
標籤: //此系列博文是《第一行Android代碼》的學習筆記,如有錯漏,歡迎指正! Android 給我們提供了大量的 UI控制項,下面我們簡單試試幾種常用的控制項。一、TextView 在布局檔案中加入TextView元素:1 <TextView android:text="This is TextView!"2 android:gravity="center"3 android:layout_width="match_parent"4
Time of Update: 2016-04-11
標籤:首先匯入架構然後通過濾鏡CIFiter產生二維碼#import <CoreImage/CoreImage.h>/** * 產生二維碼 */- (void)creat{ //1.建立過濾對象 CIFilter *filter = [CIFilter filterWithName:@"CIQRCodeGenerator"];
Time of Update: 2016-04-11
標籤:iOS之NSPredicate(Regex和UIBarController)本文轉寄至:1190000000623005 NSPredicate,這個類和我上一篇博文中提到的valueForKeyPath一樣很強大。它的使用主要集中在兩個方法中NSArray- (NSArray *)filteredArrayUsingPredicate:(NSPredicate *)predicate;NSMutableArray-
Time of Update: 2016-04-11
標籤:Js apply方法詳解 我在一開始看到javascript的函數apply和call時,非常的模糊,看也看不懂,最近在網上看到一些文章對apply方法和call的一些樣本,總算是看的有點眉目了,在這裡我做如下筆記,希望和大家分享.. 如有什麼不對的或者說法不明確的地方希望讀者多多提一些意見,以便共同提高.. 主要我是要解決一下幾個問題: 1.apply和call的區別在哪裡 2.什麼情況下用apply,什麼情況下用call
Time of Update: 2016-04-11
標籤:Problem 1604 - Play AppleTime Limit: 1000MS Memory Limit: 65536KB Total Submit: 442 Accepted: 177 Special Judge: NoDescriptionThere are N apples. Two people take turns to either: 1. Divide the
Time of Update: 2016-04-11
標籤: 在/res/anim/ 建立檔案tran_out.xml添加<translate>節點設定x軸來源座標android:fromXDelta=”0”設定x軸目的座標android:toXDelte=”-100%p” 整個父表單設定y軸來源座標android:fromYDelta=”0”設定y軸目的座標android:toYDelta=”0”設定執行時間
Time of Update: 2016-04-11
標籤:今天用到hibernate查詢資料庫資料(sql server),出現異常:No Dialect mapping for JDBC
Time of Update: 2016-04-11
標籤:three.xml:<?xml version="1.0" encoding="utf-8"?><LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="match_parent" android:orientation="vertical" >
Time of Update: 2016-04-11
標籤:公司跑項目時,遇到過非常詭異的報錯,資訊如下:org.hibernate.hql.internal.ast.QuerySyntaxException: User is not mapped [select count(*) from User u where u.userName=? and u.userPassword=? ]Caused by: org.hibernate.hql.internal.ast.QuerySyntaxException: User is not
Time of Update: 2016-04-11
標籤:TabLayout應用中通過Tab在不同視圖中間切換對於材料設計而言並非一個新的概念,他們等同於首頁的頂級導航模式或者在應用內組織不同群組的內容,。 TabLayout既實現了固定的選項卡 - view的寬度平均分配,也實現了可滾動的選項卡 - view寬度不固定同時可以橫向滾動。選項卡可以在程式中動態添加: TabLayout tabLayout = (TabLa
Time of Update: 2016-04-11
標籤:AppBarLayoutAppBarLayout跟它的名字一樣,把容器類的組件全部作為AppBar。是繼承LinerLayout實現的一個ViewGroup容器組件,它是為了Material Design設計的App Bar,支援手勢滑動操作。預設的AppBarLayout是垂直方向的,它的作用是把AppBarLayout包裹的內容都作為AppBar。 就是把Toolbar和TabLayout放到了AppBarLayout中,讓他們當做一個整體作為AppBar
Time of Update: 2016-04-11
標籤:1、返回按鈕的顏色self.navigationController.navigationBar.tintColor = [UIColor whiteColor];2、設定返回按鈕的內容A -> B在push的時候,在A中添加代碼:UIBarButtonItem *backItem = [[UIBarButtonItem alloc] init];backItem.title = @"你的文字";self.navigationItem.backBarButtonItem =
Time of Update: 2016-04-11
標籤:轉自:http://www.jianshu.com/p/5178204a58d6?hmsr=toutiao.io&utm_medium=toutiao.io&utm_source=toutiao.io 1. RuntimeObjective-C 是面相運行時的語言(runtime oriented language),就是說它會儘可能的把編譯和連結時要執行的邏輯延遲到運行時。這就給了你很大的靈活性,你可以按需要把訊息重新導向給合適的對象,你甚
Time of Update: 2016-04-11
標籤:“KeyMob移動廣告彙總平台(www.keymob.com)”是“湖南常樂網路”旗下為行動裝置
Time of Update: 2016-04-11
標籤:一、資料庫在項目開發中,通常都需要對資料進行離線緩衝的處理,如新聞資料的離線緩衝等。離線緩衝一般都是把資料儲存到項目的沙箱中。有以下幾種方式: 1. 歸檔:NSKeyedArchiver 2. 喜好設定:NSUserDefaults 3.
Time of Update: 2016-04-11
標籤:activity_ui6.xml<?xml version="1.0" encoding="utf-8"?><GridView xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="match_parent" android:id="@+id/gv_1"
Time of Update: 2016-04-11
標籤:Fragment中的代碼 context 是null public class PlaceholderFragment extends Fragment{Context context = getActivity();}這樣定義的context是null。當然咯,我實際代碼不是這樣寫的,可是這個意思。假設是在Activity中就不會是空。在Fragment中就是null。Activity中的代碼 context不是nullpublic class MainActivity
Time of Update: 2016-04-11
標籤:本文適用於從Eclipse轉AndroidStudio的開發人員最近打算寫一個系列的android初級開發教程,預計40篇以上的文章,結合我實際工作中的經驗,寫一些工作中經常用到的技術,讓初學者可以少走彎路,這是本系列的第一篇文章,345大神寫的。原文地址一. 下載安裝JDK安裝並配置JAVA_HOME環境變數這個就略過了,純小白請自行百度Android Studio安裝截止到2016年4月9日Android
Time of Update: 2016-04-11
標籤:關於ios 下動態計算常值內容的高度,經過查閱和網上搜素,現在看到的有以下幾種方法:1、// 擷取字串的大小 ios6- (CGSize)getStringRect_:(NSString*)aString { CGSize size; UIFont *nameFont=[UIFont fontWithName:@"Helvetica"
Time of Update: 2016-04-11
標籤:1. 首先現在ZXing的lib2. 在Android Studio整合ZXing。 public void scan(View view){ startActivityForResult(new Intent(MainActivity.this, CaptureActivity.class),0); } 以上是開啟掃一掃。 二維碼的產生可以去http://cli.im/3. 建立二維碼 public void make(View view){