简体   繁体   English

如何在Xcode中找到光标所在的代码行?

[英]How can you find out the line of code your cursor is on in Xcode?

如何在Xcode中找到光标所在的代码行?

Turn on 'Show Line Numbers' in the text editing preferences. 在文本编辑首选项中启用“显示行号”。 Here's a screen shot for Xcode 4: 这是Xcode 4的屏幕截图:

Xcode 4文本编辑首选项


and for Xcode 3: 对于Xcode 3:

Xcode 3文本编辑首选项

For me, anyway, right below the title bar of the editor window it says the name of the file and the line number: 对我来说,无论如何,在编辑器窗口的标题栏下面,它会显示文件的名称和行号:

ImportExportExample.java:32 ImportExportExample.java:32

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 XCode Instruments - 找到代码泄漏的行 - XCode Instruments - find a line where code is leaking 在Xcode中,您可以直接向接口元素添加代码吗? - In Xcode can you add code directly to an interface element? 如何使用查找和替换在 Xcode 中用单个新行替换多个新行 - how to replace multi new line with single new line in Xcode using Find & Replace 如何防止Lion在崩溃后显示“是否要还原Windows” - How can I prevent Lion to display the Do you want to restore your windows after a crash 如何修复 Xcode 6、Mac OS X Yosemite 或 Mavericks 中的“代码对象在子组件中根本没有签名:”? - How do you fix "code object is not signed at all In subcomponent:" in Xcode 6, Mac OS X Yosemite or Mavericks? 你如何测试你的Cocoa GUI? - How do you test your Cocoa GUIs? 如何将插入符号(光标)移动到可可中的行尾 - How to move caret (cursor) to the end of the line in cocoa 如何找出NSDictionary元素的类型? - How can I find out the type of a NSDictionary element? 如何确定对象是否实现了特定方法? - How can I find out if an object implements a particular method? 你能动态地将CFBundleDocumentTypes分配给你的Cocoa应用程序吗? - Can you dynamically assign CFBundleDocumentTypes to your Cocoa application?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM