I'm using an array of arrays for each row of the map to make a virtual grid of what the map looks like. Each tile location will either have a 0 or a 1 to determine whether that tile is empty or if there is already an object occupying that tile.The array would look something like this: The 1's display the inpenetrable border around the map. All the 0's are open spaces where an object, such as a tree, rock, or building can be placed.1, 1, 1, 1, 1, 1, 1, 1, 1, 11, 0, 0 , 0, 0, 0, 0, 0, 0, 11, 0, 0 , 0, 0, 0, 0, 0, 0, 11, 0, 0 , 0, 0, 0, 0, 0, 0, 11, 0, 0 , 0, 0, 0, 0, 0, 0, 11, 0, 0 , 0, 0, 0, 0, 0, 0, 11, 0, 0 , 0, 0, 0, 0, 0, 0, 11, 0, 0 , 0, 0, 0, 0, 0, 0, 11, 0, 0 , 0, 0, 0, 0, 0, 0, 11, 1, 1, 1, 1, 1, 1, 1, 1, 1What I'm trying to do is figure out if I have an object of 2x2 tile size, how many different locations this 2x2-tiled object will fit!This is what I have so far:for rowNumber in minRow...maxRow{ var theRow = tiles[rowNumber] for columnNumber in minColumn...maxColumn{ if(theRow[columnNumber] == 0){ //
Search results for
column
2,047 results found
Selecting any option will automatically load the page
Post
Replies
Boosts
Views
Activity
Which model do you use? I have 5s with 9.0.2 and similar problems. I faced with touchscreen problem immediately after upgrading to 9.0. Both 9.0.1 and 9.0.2 didn't fix the issue. Sometimes touchscreen is unresponsive, I even can't answer on incoming call 🙂 But most of time the screen lives by its own life. I found that screen can touch itself at 4th row, 3rd column, even if I don't touch it at all. I placed there the Calculator app as it doesn't have many hard functions. I tried to reset and restore my phone, but failed. The problem still happens. So, I just wait for 9.1 release
Topic:
App & System Services
SubTopic:
Core OS
Tags:
I set a custom class of UIScrollView, my intention is to show a graph in ScrollView, say for example a heartbeat from time to time start x1 to end x2. But in ScrollView it is shown only the part you can see in the screen base, if I run the view it works well, but the graph does not flow, why ?class GraphScrollView: UIScrollView { required init?(coder aDecoder: NSCoder) { / super.init(coder: aDecoder) } var startColor: UIColor = UIColor(red: 0.9, green: 0.2, blue: 0.2, alpha: 0.5) var endColor: UIColor = UIColor(red: 0.7, green: 0.3, blue: 0.3, alpha: 0.5) override func drawRect(var rect: CGRect) { layer.cornerRadius = 5 layer.borderColor = UIColor(red: 0.7, green: 0.2, blue: 0.2, alpha: 0.7).CGColor layer.borderWidth = 2 let marginX = CGFloat(10) let marginY = CGFloat(10) let margin = CGFloat(5 + marginY) var arrayDistance:[Double] = [] for var i = 0; i < arrayLocation.count - 1 ; i++ { let p1 = arrayLocation[i] let p2 = arrayLocation[i + 1] let distance = Location().get_distance(p1, p2: p2) arrayDistance.
This is true if you put them side-by-side. However, if you stack them all in a column then they work like UISwitches. -Brian
Topic:
App & System Services
SubTopic:
Core OS
Tags:
How do you stack them in a column or do you mean using 2 segmented button and have 1 segment for each of them?
Topic:
App & System Services
SubTopic:
Core OS
Tags:
I wish I could post screenshots. Basically I have a Settings dialog in my app that uses a bunch of yes/no switches. I put all the options in a column from top to bottom: MUSIC: ON/OFF, REDUCE MOTION: ON/OFF, etc. All of the ON/OFF switches are done as UISegmentedControllers, but the catch is that you can't move focus horizontally with those, or it changes the switch's on/off value. But, you can move up and down, so I simply put all those settings in a column so the user only has to move up/down to select the setting that they want to change.-Brian
Topic:
App & System Services
SubTopic:
Core OS
Tags:
I custome mainpage of application, and it's have more columns. So how to I can do it?It's look like photo in here link: http://techcrunch.com/2014/10/09/facebook-photo-collage/Thank you!
XLS files are complex so I’m going to ignore that.CSV files are a lot less complex—although more complex than most folks think—so I’ll focus there. Here’s some simplifying assumptions:you’re build an iOS or Mac app, and thus have access to Foundationthe data will be small enough to fit in memory easilythe text encoding will be UTF-8the line breaks will be Windows style (CR LF)the items won’t include any weird characters (like CR or LF)Based on those requirements, here’s an implementation that optimised for readability:import Foundation func quoteColumn(column: String) -> String { if column.containsString(,) || column.containsString() { return + column.stringByReplacingOccurrencesOfString(, withString: ) + } else { return column } } func commaSeparatedValueStringForColumns(columns: [String]) -> String { return columns.map {column in quoteColumn(column) }.joinWithSeparator(,) } func commaSeparatedValueDataForLines(lines: [[String]]) -> NSData { return line
Topic:
Programming Languages
SubTopic:
Swift
Tags:
I try to parse all the content of a specific column in a website into an NSMutableArray (at the end, I want to insert it into an Parse database).Can anyone tell me how can I do that?The URL is:http://www1.shufersal.co.il/supersol_he/branches/search/brancheslocation.htmlThe XPath is: //[@id=MainBody]/table/tbody/tr[2]/td/table/tbody/tr/td[3]/table/tbody/tr[4]/td/table/tbody/tr[5]/td/table/tbody/tr[2]/td[8](I need the section ״כתובת״, sorry for the languege 🙂 ).Does anybody can help me do that in Objective c? Thanks!!!My implementation: NSURL *tutorialUrl=[NSURL URLWithString:@http://www1.shufersal.co.il/supersol_he/branches/search/brancheslocation.html]; NSData *tutorialsHtmlData=[NSData dataWithContentsOfURL:tutorialUrl]; TFHpple *tutorialParser=[TFHpple hppleWithHTMLData:tutorialsHtmlData]; NSString *tutorialXpathQueryString=@//[@id=MainBody]/table/tbody/tr[2]/td/table/tbody/tr/td[3]/table/tbody/tr[4]/td/table/tbody/tr[5]/td/table/tbody/tr[2]/td[8]; NSArray *tutorialsNodes=[tutorialParser searchWit
I'm trying to create a column that represents a unique record ID, and can't seem to figure out how to create it. I'm using CoreData on iOS 9.x with a SQLite backing store.The simple scenario is a table which should only have a single record which represents the last stored game number for each of several different game levels. I want to ensure that there is only one record in this table so that I can query the proper column for the last game number of that game type or level.The idea being a single record that would have columns such as:Last Easy Game Number PlayedLast Hard Game Number Played, etc.The game type/level, game number is then an indexed value in the game level preset values table. In this way I can query the last game number, search for a value greater than that, or else wrap around to game number 1 of that level to start the game.The ability to create a unique index or primary key is beyond my mental grasp, (or use the record UUID saved by SQLite) but I know it is in ei
I'm starting to see telemetry come back for our latest release build with Xcode 7. I'm seeing what seems to be data corruption for our CoreData databases, but only on iOS 9. I'm seeing two forms, both when the application tries to reopen the database on launch:Could not create history store with error Error Domain=NSCocoaErrorDomain Code=259 The file couldn’t be opened because it isn’t in the correct format. UserInfo={NSSQLiteErrorDomain=26, NSUnderlyingException=File at path does not appear to be a SQLite database: /var/mobile/Containers/Data/Application/95677339-A20B-4EBF-B1B4-0AB6AC5E1080/Library/Application Support/History.db}That one I have no ideas on. It's like our database just became magically corrupted.Could not create thumbnail store with error Error Domain=NSCocoaErrorDomain Code=134110 An error occurred during persistent store migration. UserInfo={destinationURL=file:///var/mobile/Containers/Data/Application/36E5990A-CF49-44C4-8C1B-9338C7A2A3FE/Library/Caches/.Thumbnails.db.migrationdestination_4
I am not sure what project C means, but to include a Class (for example TheClassToAdd) in an Xcode project you copy the .h and .m file into the folder in the left column in Xcode and you add this line before the @interface in the .m file or the .h file from which you wish to reference methods in the Class:#import TheClassToAdd.h
Topic:
Programming Languages
SubTopic:
General
Tags:
{ columns:[ {label:Group Id,type:STRING}, {label:User Id,type:STRING}, {label:Device Id,type:STRING}, {label:Group Name,type:STRING}, {label:User Name,type:STRING}, {label:Email Address,type:STRING}, {label:Device Name,type:STRING}, {label:Device Status,type:STRING}, {label:Created When,type:DATETIME}, {label:Deleted When,type:DATETIME}, {label:Device Type,type:NUMBER}, {label:OS Name,type:STRING}, {label:Manufacturer,type:STRING}, {label:Client Version,type:STRING}, {label:Platform Type,type:STRING}, {label:Workspace Type,type:STRING}, {label:Number Of Sync Assets,type:NUMBER}, {label:Number Of Backup Assets,type:NUMBER}, {label:First Backup Start Date,type:DATETIME}, {label:First Backup End Date,type:DATETIME}, {label:Last Contact Time,type:DATETIME} ], rows:[ { values:[ 137260229254447104, 137260231938801664, , testgroup1415989388599, with role Admin,user2WViRiQVyU, AdminAYKHpd077D@email.com, null, 0, , , , null, null, null, , SYNC, 0, 0, , , ] }, { values:[ 137260229254447104, 137260239085895680
Topic:
Developer Tools & Services
SubTopic:
Xcode
Tags:
Try to avoid things like NSArray if you're writing new Swift code. Be explicit about your types whenever possible.print(<table><thead>) if let columns = json[columns] as? [[String : String]] { for column in columns { let label = column[label]! print(<th>(label)</th>) } } print(</thead><tbody>) if let rows = json[rows] as? [[String : [String]]] { for row in rows { print(<tr>) for value in row[values]! { print( <td>(value)</td>, terminator: ) } print(</tr>) } } print(</tbody></table>)
Topic:
Developer Tools & Services
SubTopic:
Xcode
Tags:
This is NOT my first app release but is my first after the ITC redesign. Can someone confirm if this is a bug or if not, what am I supposed to do:I requested 99 Promo Codes for my app. The web tool generated them and listed them in a column. I select all and copy, then paste into a document. ALL the codes paste in as one long string. I tried pasting into a standard text editor, into a Word, into other editors with no difference.So then I tried from the TXT file downloaded from ITC. SAME THING. The file is one big block of text with no seperation between codes! What am I supposed to do with this other than CAREFUL MANUAL editing??