getcolor

    0熱度

    1回答

    我試圖獲取像素的顏色。我在我的OnCreate如下: bitmap = img.getDrawingCache(); int pixel = bitmap.getPixel(5,5); int r = Color.red(pixel); int g = Color.green(pixel); int b = Color.blue(pixel); Toast.makeText(getA

    0熱度

    1回答

    LinearLayout linearLayout = (LinearLayout) findViewById(R.id.linear); int color = ContextCompat.getColor(getContext(), mColorResourceId); linearLayout.setBackgroundColor(color); 我有這行代碼: mColorReso

    42熱度

    7回答

    我想寫一個日曆應用程序。這是真正反覆出現的項目,在DB架構的作品中引發了一些問題。我會喜歡一些關於如何組織這一點的意見。 如果用戶創建一個事件,並輸入它重複所有人星期一,永遠是什麼?我怎麼能將所有這些存儲在數據庫中?我無法創造無限的事件。我只是在那裏放置一張桌子,裏面有相關信息,以便我可以計算出所有事件的發生地點?如果是這樣,每次用戶查看日曆的新部分時,我都必須計算它們。如果他們翻閱了幾個月,但他

    0熱度

    1回答

    我有一個簡單的按鈕,我想提出的圖像裏面,所以我有這樣的代碼: myButton = [[UIButton alloc] initWithFrame:CGRectMake(20, 13, 116, 138)]; UIImage *image = [UIImage imageWithContentsOfFile:[[NSBundle mainBundle] pathForResource:[se

    1熱度

    3回答

    我將一個glassfish項目轉換爲IBM WAS Liberty,非常困難我目前遇到訪問在Liberty中配置的連接池的問題(server.xml)利用jndi(jdbc/dataphile)。 我週期性地得到一個缺少類型com.ibm.ws.rsadapter.jdbc.WSJdbcDataSource錯誤。 下面是一些更增加的細節: <library id="DB2JCC4Lib">